Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RandomRange ¶
RandomRange returns a random integer (using rand.Reader as the entropy source) between 0 and max
Types ¶
type FakeNameGenerator ¶
func (FakeNameGenerator) New ¶
func (fng FakeNameGenerator) New() (string, error)
type NameGenerator ¶
NameGenerator describes an object capable of generating new environment names
type WordnetNameGenerator ¶
type WordnetNameGenerator struct {
// contains filtered or unexported fields
}
WordnetNameGenerator generates names from WordNet data
func NewWordnetNameGenerator ¶
func NewWordnetNameGenerator(filename string, logger *log.Logger) (*WordnetNameGenerator, error)
NewWordnetNameGenerator loads filename (must be a gzip & JSON-encoded wordset list) and returns a WordnetNameGenerator
func (*WordnetNameGenerator) New ¶
func (wng *WordnetNameGenerator) New() (string, error)
New returns a randomly-generated name of the form {adjective}-{noun}
Click to show internal directories.
Click to hide internal directories.