edge

package
v0.0.0-...-f579556 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 25, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Codes = []string{
		ConiferHills: "CH",
		GrassyHills:  "GH",
		OceanCoast:   "OC",
		Prairie:      "PR",
		River:        "R",
		RiverFord:    "RF",
		RockyHills:   "RH",
		Swamp:        "SW",
	}
	Description = []string{
		ConiferHills: "Conifer Hills",
		GrassyHills:  "Grassy Hills",
		OceanCoast:   "Ocean Coast",
		Prairie:      "Prairie",
		River:        "River",
		RiverFord:    "River Fords",
		RockyHills:   "Rocky Hills",
		Swamp:        "Swamp",
	}
	LongDescription = []string{
		ConiferHills: "Conifer hills.",
		GrassyHills:  "Grassy hills.",
		OceanCoast:   "Ocean coastline.",
		Prairie:      "Prairie",
		River:        "River with no crossings.",
		RiverFord:    "Shallow spots that are ways across rivers.",
		RockyHills:   "Rocky hills.",
		Swamp:        "Swamp",
	}
)

Functions

This section is empty.

Types

type Edge

type Edge int
const (
	Unknown Edge = iota
	ConiferHills
	GrassyHills
	OceanCoast
	Prairie
	River
	RiverFord
	RockyHills
	Swamp
)

the enums for Edge must be sorted by the Code string value. if they aren't, the UnmarshalJSON will fail.

func (Edge) Code

func (e Edge) Code() string

func (Edge) Description

func (e Edge) Description() string

Description returns a description of the code.

func (Edge) LongDescription

func (e Edge) LongDescription() string

LongDescription returns an expanded description of the code.

func (Edge) MarshalJSON

func (e Edge) MarshalJSON() ([]byte, error)

MarshalJSON implements the json.Marshaler interface

func (Edge) String

func (e Edge) String() string

String implements the string.Stringer interface

func (*Edge) UnmarshalJSON

func (e *Edge) UnmarshalJSON(b []byte) error

UnmarshalJSON implements the json.Unmarshaler interface

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL