17 lines
331 B
Go
17 lines
331 B
Go
|
package generation
|
||
|
|
||
|
import (
|
||
|
"fmt"
|
||
|
|
||
|
"github.com/boombuler/barcode"
|
||
|
"github.com/boombuler/barcode/twooffive"
|
||
|
)
|
||
|
|
||
|
func generate2of5(parameters Parameters) (barcode.Barcode, error) {
|
||
|
barcode, err := twooffive.Encode(parameters.Content, false)
|
||
|
if err != nil {
|
||
|
fmt.Println("Error creating Barcode", err)
|
||
|
}
|
||
|
return barcode, err
|
||
|
}
|