synopsis

package
v0.0.0-...-116fc4f Latest Latest
Warning

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

Go to latest
Published: Mar 5, 2018 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Arg

type Arg struct {
	CmdTokenAttributes
	XMLName  xml.Name `xml:"arg"`
	Literal  string   `xml:",chardata"`
	Variable string   `xml:"replaceable,omitempty"`
}

http://tdg.docbook.org/tdg/4.5/arg.html

func (Arg) String

func (arg Arg) String() string

type ChoiceType

type ChoiceType uint8

Choice indicates whether the Arg is required (Req or Plain) or optional (Opt). Arguments identified as Plain are required, but are shown without additional decoration.

const (
	ChoiceOptional ChoiceType = iota
	ChoicePlain
	ChoiceRequired
)

func ChoiceFromAttr

func ChoiceFromAttr(attr xml.Attr) (choice ChoiceType, err error)

func (ChoiceType) String

func (choice ChoiceType) String() string

func (*ChoiceType) UnmarshalXMLAttr

func (choice *ChoiceType) UnmarshalXMLAttr(attr xml.Attr) error

type CmdSynopsis

type CmdSynopsis struct {
	CmdSynopsisTokenContainer
	XMLName xml.Name `xml:"cmdsynopsis"`
	Command string
}

http://tdg.docbook.org/tdg/4.5/cmdsynopsis.html

func (*CmdSynopsis) DecodeTags

func (synopsis *CmdSynopsis) DecodeTags(d *xml.Decoder, start xml.StartElement) (err error)

func (*CmdSynopsis) UnmarshalXML

func (synopsis *CmdSynopsis) UnmarshalXML(d *xml.Decoder, start xml.StartElement) (err error)

type CmdSynopsisTokenContainer

type CmdSynopsisTokenContainer struct {
	Tokens []SynopsisFragment
}

type CmdTokenAttributes

type CmdTokenAttributes struct {
	// opt, plain, req
	Choice ChoiceType `xml:"choice,attr"`
	// repeat, noreapeat
	Repeat RepeatAttr `xml:"rep,attr"`
}

type Group

type Group struct {
	XMLName xml.Name `xml:"group"`
	CmdTokenAttributes
	CmdSynopsisTokenContainer
}

http://tdg.docbook.org/tdg/4.5/group.html

func (*Group) DecodeTags

func (group *Group) DecodeTags(d *xml.Decoder, start xml.StartElement) (err error)

func (*Group) String

func (group *Group) String() string

func (*Group) UnmarshalXML

func (group *Group) UnmarshalXML(d *xml.Decoder, start xml.StartElement) (err error)

type RepeatAttr

type RepeatAttr bool

func (*RepeatAttr) UnmarshalXMLAttr

func (repeat *RepeatAttr) UnmarshalXMLAttr(attr xml.Attr) (err error)

type SynopsisFragment

type SynopsisFragment interface {
	fmt.Stringer
}

Arg | Group http://tdg.docbook.org/tdg/4.5/synopfragment.html

Jump to

Keyboard shortcuts

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