Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Context ¶
type Context map[string]TermDefinition
Context is a JSON-LD context.
func (Context) Inverse ¶
func (ctx Context) Inverse() InverseContext
func (*Context) UnmarshalJSON ¶
type Document ¶
type Document struct { Context Context `json:"@context"` Graph Graph `json:"@graph"` ID string `json:"@id"` Type Type `json:"@type"` Values map[string]Node }
func NewDocument ¶
func NewDocument() *Document
func (*Document) MarshalJSON ¶
func (*Document) UnmarshalJSON ¶
type InverseContext ¶
type InverseContext map[string]InverseContextEntry
type InverseContextEntry ¶
type InverseContextEntry struct { ID string Term TermDefinition }
type Node ¶
type Node struct { ID string `json:"@id"` Type Type `json:"@type,omitempty"` Value string `json:"@value,omitempty"` Language string `json:"@language,omitempty"` Values map[string]any }
func (*Node) MarshalJSON ¶
func (*Node) UnmarshalJSON ¶
type NodeReference ¶
type NodeReference struct {
ID string `json:"@id"`
}
type NodeReferences ¶
type NodeReferences []NodeReference
func (NodeReferences) MarshalJSON ¶
func (ns NodeReferences) MarshalJSON() ([]byte, error)
func (*NodeReferences) UnmarshalJSON ¶
func (ns *NodeReferences) UnmarshalJSON(bytes []byte) error
type TermDefinition ¶
func (*TermDefinition) UnmarshalJSON ¶
func (t *TermDefinition) UnmarshalJSON(bytes []byte) error
Source Files ¶
Click to show internal directories.
Click to hide internal directories.