instance

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Oct 28, 2024 License: Apache-2.0 Imports: 5 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LinkedProperty

type LinkedProperty struct {
	DisplayName          string `json:"displayName"`
	From                 string `json:"from"`
	ID                   string `json:"id"`
	Name                 string `json:"name"`
	SchemaRelationshipID string `json:"schemaRelationshipId"`
	To                   string `json:"to"`
	Type                 string `json:"type"`
}

type Property

type Property struct {
	ConceptTitle bool `json:"conceptTitle"`
	// DataType can be a string or a JSON object
	DataType    json.RawMessage `json:"dataType"`
	Default     bool            `json:"default"`
	DisplayName string          `json:"displayName"`
	Locked      bool            `json:"locked"`
	Name        string          `json:"name"`
	Required    bool            `json:"required"`
	Value       any             `json:"value"`
}

func (Property) ArrayValue

func (p Property) ArrayValue() (any, error)

func (Property) DecodeDataType

func (p Property) DecodeDataType() (any, error)

func (Property) LongValue

func (p Property) LongValue() (int64, error)

type Proxy

type Proxy struct {
	ProxyID
	ProxyPackage
}

type ProxyID

type ProxyID struct {
	ID string `json:"id"`
}

type ProxyPackage

type ProxyPackage struct {
	Content ProxyPackageContent `json:"content"`
}

ProxyPackage should also have "children" and "properties" slices, but we don't need them for now

type ProxyPackageContent

type ProxyPackageContent struct {
	CreatedAt     time.Time `json:"createdAt"`
	DatasetId     string    `json:"datasetId"`
	DatasetNodeId string    `json:"datasetNodeId"`
	ID            string    `json:"id"`
	Name          string    `json:"name"`
	NodeID        string    `json:"nodeId"`
	OwnerID       int       `json:"ownerId"`
	PackageType   string    `json:"packageType"`
	State         string    `json:"state"`
	UpdatedAt     time.Time `json:"updatedAt"`
}

type RawFromFile

type RawFromFile [2]json.RawMessage

RawFromFile represents the structure of proxy instances as they appear in the downloaded files. The first json.RawMessage is a ProxyID and the second is a ProxyPackage A downloaded file will contain a []RawFromFile

type Record

type Record struct {
	CreatedAt time.Time  `json:"createdAt"`
	CreatedBy string     `json:"createdBy"`
	ID        string     `json:"id"`
	Type      string     `json:"type"`
	UpdatedAt time.Time  `json:"updatedAt"`
	UpdatedBy string     `json:"updatedBy"`
	Values    []Property `json:"values"`
}

Jump to

Keyboard shortcuts

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