urbandictionary

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Jun 30, 2020 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

Package urbandictionary implements Urban Dictionary definition of words using their JSON API.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Definition

type Definition struct {
	Word                   string
	Definition             string
	Example                string
	Author                 string
	Defid                  int
	Permalink              string
	Current_vote           string
	Thumbs_up, Thumbs_down int
	Term                   string
	Type                   string
}

func (*Definition) String

func (d *Definition) String() string

type Result

type Result struct {
	Has_related_words bool
	Pages             int
	Result_type       string
	Sounds            []string
	Total             int
	List              []Definition
}

func Define

func Define(term string) (*Result, error)

Define gets definition of term on Urban Dictionary and populates a Result.

func (*Result) String

func (r *Result) String() string

Jump to

Keyboard shortcuts

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