Documentation ¶
Overview ¶
Package edges defines constants for Kythe edges.
Index ¶
- Constants
- func Canonical(kind string) string
- func IsAnchorEdge(kind string) bool
- func IsForward(kind string) bool
- func IsReverse(kind string) bool
- func IsVariant(x, y string) bool
- func Mirror(kind string) string
- func OrdinalKind(kind string) bool
- func ParamIndex(i int) string
- func ParseOrdinal(kind string) (base string, ordinal int, hasOrdinal bool)
Constants ¶
View Source
const ( ChildOf = Prefix + "childof" Extends = Prefix + "extends" ExtendsPrivate = Prefix + "extends/private" ExtendsPrivateVirtual = Prefix + "extends/private/virtual" ExtendsProtected = Prefix + "extends/protected" ExtendsProtectedVirtual = Prefix + "extends/protected/virtual" ExtendsPublic = Prefix + "extends/public" ExtendsPublicVirtual = Prefix + "extends/public/virtual" ExtendsVirtual = Prefix + "extends/virtual" Generates = Prefix + "generates" Named = Prefix + "named" Overrides = Prefix + "overrides" Param = Prefix + "param" Satisfies = Prefix + "satisfies" Typed = Prefix + "typed" )
Edge kind labels
View Source
const ( Completes = Prefix + "completes" CompletesUniquely = Prefix + "completes/uniquely" Defines = Prefix + "defines" DefinesBinding = Prefix + "defines/binding" Documents = Prefix + "documents" Ref = Prefix + "ref" RefCall = Prefix + "ref/call" RefImplicit = Prefix + "ref/implicit" RefCallImplicit = Prefix + "ref/call/implicit" RefImports = Prefix + "ref/imports" RefInit = Prefix + "ref/init" RefInitImplicit = Prefix + "ref/init/implicit" Tagged = Prefix + "tagged" )
Edge kinds associated with anchors
View Source
const Prefix = schema.Prefix + "edge/"
Prefix defines the common prefix for all Kythe edge kinds.
Variables ¶
This section is empty.
Functions ¶
func IsAnchorEdge ¶
IsAnchorEdge reports whether kind is one associated with anchors.
func IsVariant ¶
IsVariant reports whether x is equal to or a subkind of y. For example, each of the following returns true:
IsVariant("/kythe/edge/defines/binding", "/kythe/edge/defines") IsVariant("/kythe/edge/defines", "/kythe/edge/defines")
Moreover IsVariant(x, y) == IsVariant(Mirror(x), Mirror(y)) for all x, y.
func OrdinalKind ¶ added in v0.0.27
OrdinalKind reports whether kind (which does not have an ordinal suffix) generally has an associated ordinal (e.g. /kythe/edge/param edges).
func ParamIndex ¶ added in v0.0.27
ParamIndex returns an edge label of the form "param.i" for the i given.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.