Documentation ¶
Index ¶
- func Read(name string) (*[]byte, error)
- func Remove(name string) error
- func Write(category *Category) error
- type Category
- func (pointer *Category) SetAnchor(anchor string) *Category
- func (pointer *Category) SetEmoji(emoji *slice.Slice) *Category
- func (pointer *Category) SetHref(href string) *Category
- func (pointer *Category) SetName(name string) *Category
- func (pointer *Category) SetNumber(number int) *Category
- func (pointer *Category) SetPosition(position int) *Category
- func (pointer *Category) SetSubcategories(subcategories *slice.Slice) *Category
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Category ¶
type Category struct { Anchor string `json:"anchor"` Emoji *slice.Slice `json:"emoji"` Href string `json:"href"` Name string `json:"name"` Number int `json:"number"` Position int `json:"position"` Subcategories *slice.Slice `json:"subcategories"` }
Category stores the categorical superset of the emoji data.
func Get ¶
Get attempts to open a Category from the emojipedia/categories folder, but panics if an error occurs.
func NewCategory ¶
func NewCategory(anchor, href, name string, number, position int, emoji, subcategories *slice.Slice) *Category
NewCategory creates a new Category pointer, requiring all struct features as arguments.
func (*Category) SetPosition ¶
SetPosition sets the Category.Position property.
Click to show internal directories.
Click to hide internal directories.