elements

package
v0.0.0-...-90603f3 Latest Latest
Warning

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

Go to latest
Published: Jul 23, 2018 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Edge

type Edge struct {
	Class       string                 `json:"class,omitempty" bson:"class,omitempty" yaml:"class,omitempty" hcl:"class,omitempty"`
	Group       string                 `json:"group" bson:"group" yaml:"group" hcl:"group"`
	Source      string                 `json:"source" bson:"source" yaml:"source" hcl:"source"`
	Destination string                 `json:"destination" bson:"destination" yaml:"destination" hcl:"destination"`
	Directed    bool                   `json:"directed" bson:"directed" yaml:"directed" hcl:"directed"`
	Properties  map[string]interface{} `json:"properties" bson:"properties" yaml:"properties" hcl:"properties"`
}

func NewEdge

func NewEdge(class string, group string, source string, destination string, directed bool, properties map[string]interface{}) *Edge

func (*Edge) GetClass

func (e *Edge) GetClass() string

func (*Edge) GetDestination

func (e *Edge) GetDestination() string

func (*Edge) GetGroup

func (e *Edge) GetGroup() string

func (*Edge) GetProperties

func (e *Edge) GetProperties() map[string]interface{}

func (*Edge) GetSource

func (e *Edge) GetSource() string

func (*Edge) IsDirected

func (e *Edge) IsDirected() bool

func (*Edge) SetProperty

func (e *Edge) SetProperty(name string, value interface{})

type Element

type Element interface {
	GetClass() string
	GetGroup() string
	GetProperties() map[string]interface{}
	SetProperty(name string, value interface{})
}

type Entity

type Entity struct {
	Class      string                 `json:"class,omitempty" bson:"class,omitempty" yaml:"class,omitempty" hcl:"class,omitempty"`
	Group      string                 `json:"group" bson:"group" yaml:"group" hcl:"group"`
	Vertex     string                 `json:"vertex" bson:"vertex" yaml:"vertex" hcl:"group"`
	Properties map[string]interface{} `json:"properties" bson:"properties" yaml:"properties" hcl:"properties"`
}

func NewEntity

func NewEntity(class string, group string, vertex string, properties map[string]interface{}) *Entity

func (*Entity) GetClass

func (e *Entity) GetClass() string

func (*Entity) GetGroup

func (e *Entity) GetGroup() string

func (*Entity) GetProperties

func (e *Entity) GetProperties() map[string]interface{}

func (*Entity) GetPropertyAsFloat64

func (e *Entity) GetPropertyAsFloat64(name string) (float64, error)

func (*Entity) GetVertex

func (e *Entity) GetVertex() string

func (*Entity) SetProperties

func (e *Entity) SetProperties(properties map[string]interface{})

func (*Entity) SetProperty

func (e *Entity) SetProperty(name string, value interface{})

Jump to

Keyboard shortcuts

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