func (v *Variant) Options() map[string]interface{} {
	if options, ok := v.Tags["DefaultToppings"]; ok {
		codes, amounts, n := splitDefaults(options.(string))
		if v.opts == nil {
			v.opts = make(map[string]interface{})
		}
		for i := 0; i < n; i++ {
			if _, ok := v.opts[codes[i]]; !ok {
				v.opts[codes[i]] = map[string]string{ToppingFull: amounts[i]}
			}
		}
	}
	return v.opts
}
Options returns a map of the Variant's options.
package dawg
import (
	"errors"
	"fmt"
	"strings"
)
var productOptQtys = map[string][]string{
	"Wings":    {"0", "0.5", "1", "1.5", "2", "3", "4", "5"},
	"Pizza":    {"0", "0.5", "1", "1.5", "2"},
	"Sandwich": {"0", "0.5", "1", "1.5"},
	"Pasta":    {"0", "1"},
}
type Item interface {
	Options() map[string]interface{}
	AddTopping(string, string, string) error
	ItemCode() string
	ItemName() string
	Category() string
}
type ItemCommon struct {
	Code string
	Name string
	Tags map[string]interface{}
	Local bool
	menu *Menu  
}
func (im *ItemCommon) ItemCode() string {
	return im.Code
}
func (im *ItemCommon) ItemName() string {
	return im.Name
}
type Product struct {
	ItemCommon
	Variants []string
	Description string
	AvailableToppings string
	AvailableSides string
	DefaultToppings string
	DefaultSides string
	ProductType string
	opts map[string]interface{}
}
func (p *Product) Options() map[string]interface{} {
	codes, amounts, n := splitDefaults(p.DefaultToppings)
	if p.opts == nil {
		p.opts = make(map[string]interface{})
	}
	for i := 0; i < n; i++ {
		if _, ok := p.opts[codes[i]]; !ok {
			p.opts[codes[i]] = map[string]string{ToppingFull: amounts[i]}
		}
	}
	return p.opts
}
func (p *Product) AddTopping(code, side, amount string) error {
	if p.opts == nil {
		p.opts = make(map[string]interface{})
	}
	top := makeTopping(side, amount, p.optionQtys())
	if top == nil {
		return fmt.Errorf("could not make a %s topping", code)
	}
	p.opts[code] = top
	return nil
}
func (p *Product) Category() string {
	return p.ProductType
}
func (p *Product) GetVariants(container ItemContainer) (variants []*Variant) {
	for _, code := range p.Variants {
		v, err := container.GetVariant(code)
		if err != nil {
			continue
		}
		variants = append(variants, v)
	}
	return variants
}
func (p *Product) optionQtys() (optqtys []string) {
	if qtys, ok := p.Tags["OptionQtys"]; ok {
		oq := qtys.([]interface{})
		optqtys = make([]string, len(oq))
		for i, q := range oq {
			optqtys[i] = q.(string)
		}
		return optqtys
	}
	return nil
}
type Variant struct {
	ItemCommon
	Price string
	ProductCode string
	Prepared bool
	product *Product
	opts    map[string]interface{}
}