schema

package
v1.0.4 Latest Latest
Warning

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

Go to latest
Published: May 26, 2022 License: BSD-3-Clause Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckValidate

func CheckValidate(v interface{}) error

Types

type AdditionalField

type AdditionalField struct {
	xml.Attr
}

func (*AdditionalField) MarshalXMLAttr

func (a *AdditionalField) MarshalXMLAttr(_ xml.Name) (xml.Attr, error)

func (*AdditionalField) UnmarshalXMLAttr

func (a *AdditionalField) UnmarshalXMLAttr(attr xml.Attr) error

type AdditionalFields

type AdditionalFields struct {
	AdditionalFields AdditionalFieldsType `xml:",any,attr"`
	CustomElements   []AnyHolder          `xml:",any"`
}

type AdditionalFieldsType

type AdditionalFieldsType []AdditionalField

type AnyHolder

type AnyHolder struct {
	MModel
}

func (*AnyHolder) MarshalXML

func (a *AnyHolder) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*AnyHolder) UnmarshalXML

func (a *AnyHolder) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type IPbase

type IPbase = TPIPbase

"Element" IPbase ...

type MModel

type MModel struct {
	XMLName xml.Name
	Attr    []xml.Attr `xml:",any,attr"`
	XML     string     `xml:",innerxml"`
}

type NodeID

type NodeID struct {
	NodeID *uuid.UUID `xml:"-" json:"node_id,omitempty"`
}

NodeID используется для маппинга элементов из бд и структуры

type SCL

type SCL struct {
	TBaseElement
	IPbase []TPIPbase `xml:"IPbase" json:"IPbase"`
	Val    []TVal     `xml:"Val" json:"Val"`
}

"ComplexType" SCL ...

func (*SCL) Validate

func (t *SCL) Validate() error

type TAcsiName

type TAcsiName string

"SimpleType" base:"xs:Name" TAcsiName ...

func (*TAcsiName) Validate

func (t *TAcsiName) Validate() error

type TBaseElement

type TBaseElement struct {
	NodeID
	AdditionalFields AdditionalFieldsType `xml:",any,attr"`
	TestAttr         string               `xml:"test,attr" json:"test"`
}

"Element"// "ComplexType" TBaseElement ...

func (*TBaseElement) Validate

func (t *TBaseElement) Validate() error

type TExtensionPTypeEnum

type TExtensionPTypeEnum string

"SimpleType" base:"xs:normalizedString" TExtensionPTypeEnum ...

func (*TExtensionPTypeEnum) Validate

func (t *TExtensionPTypeEnum) Validate() error

type TIEDNameIsNone

type TIEDNameIsNone string

"SimpleType" base:"tAcsiName" TIEDNameIsNone ...

func (*TIEDNameIsNone) Validate

func (t *TIEDNameIsNone) Validate() error

type TP

type TP struct {
	NodeID
	*TPAddr  `xml:",chardata" json:",omitempty"`
	TypeAttr TPTypeEnum `xml:"type,attr" json:"type"`
}

"ComplexType" TP ...

func (*TP) Validate

func (t *TP) Validate() error

type TPAddr

type TPAddr string

"SimpleType" base:"xs:normalizedString" TPAddr ...

func (*TPAddr) Validate

func (t *TPAddr) Validate() error

type TPIPbase

type TPIPbase struct {
	TP
}

"ComplexType" TPIPbase ...

func (*TPIPbase) Validate

func (t *TPIPbase) Validate() error

type TPIPv6IGMPv3Src

type TPIPv6IGMPv3Src struct {
	TPIPv6base
	TypeAttr TPTypeEnum `xml:"type,attr" json:"type"`
}

"ComplexType" TPIPv6IGMPv3Src ...

func (*TPIPv6IGMPv3Src) Validate

func (t *TPIPv6IGMPv3Src) Validate() error

type TPIPv6base

type TPIPv6base struct {
	TP
}

"ComplexType" TPIPv6base ...

func (*TPIPv6base) Validate

func (t *TPIPv6base) Validate() error

type TPTypeEnum

type TPTypeEnum struct {
	Content string `xml:",chardata" json:",omitempty"`
	// contains filtered or unexported fields
}

"SimpleType" TPTypeEnum is UNION type

func (*TPTypeEnum) IsEmpty

func (t *TPTypeEnum) IsEmpty() bool

func (*TPTypeEnum) MarshalXMLAttr

func (t *TPTypeEnum) MarshalXMLAttr(name xml.Name) (xml.Attr, error)

func (*TPTypeEnum) UnmarshalXMLAttr

func (t *TPTypeEnum) UnmarshalXMLAttr(attr xml.Attr) error

func (*TPTypeEnum) Validate

func (t *TPTypeEnum) Validate() error

type TPredefinedPTypeEnum

type TPredefinedPTypeEnum string

"SimpleType" base:"xs:Name" TPredefinedPTypeEnum ...

const (
	TPredefinedPTypeEnum_IP                 TPredefinedPTypeEnum = "IP"
	TPredefinedPTypeEnum_IPSUBNET           TPredefinedPTypeEnum = "IP-SUBNET"
	TPredefinedPTypeEnum_IPGATEWAY          TPredefinedPTypeEnum = "IP-GATEWAY"
	TPredefinedPTypeEnum_OSINSAP            TPredefinedPTypeEnum = "OSI-NSAP"
	TPredefinedPTypeEnum_OSITSEL            TPredefinedPTypeEnum = "OSI-TSEL"
	TPredefinedPTypeEnum_OSISSEL            TPredefinedPTypeEnum = "OSI-SSEL"
	TPredefinedPTypeEnum_OSIPSEL            TPredefinedPTypeEnum = "OSI-PSEL"
	TPredefinedPTypeEnum_OSIAPTitle         TPredefinedPTypeEnum = "OSI-AP-Title"
	TPredefinedPTypeEnum_OSIAPInvoke        TPredefinedPTypeEnum = "OSI-AP-Invoke"
	TPredefinedPTypeEnum_OSIAEQualifier     TPredefinedPTypeEnum = "OSI-AE-Qualifier"
	TPredefinedPTypeEnum_OSIAEInvoke        TPredefinedPTypeEnum = "OSI-AE-Invoke"
	TPredefinedPTypeEnum_MACAddress         TPredefinedPTypeEnum = "MAC-Address"
	TPredefinedPTypeEnum_APPID              TPredefinedPTypeEnum = "APPID"
	TPredefinedPTypeEnum_VLANPRIORITY       TPredefinedPTypeEnum = "VLAN-PRIORITY"
	TPredefinedPTypeEnum_VLANID             TPredefinedPTypeEnum = "VLAN-ID"
	TPredefinedPTypeEnum_SNTPPort           TPredefinedPTypeEnum = "SNTP-Port"
	TPredefinedPTypeEnum_MMSPort            TPredefinedPTypeEnum = "MMS-Port"
	TPredefinedPTypeEnum_DNSName            TPredefinedPTypeEnum = "DNSName"
	TPredefinedPTypeEnum_IPv6FlowLabel      TPredefinedPTypeEnum = "IPv6FlowLabel"
	TPredefinedPTypeEnum_IPv6ClassOfTraffic TPredefinedPTypeEnum = "IPv6ClassOfTraffic"
	TPredefinedPTypeEnum_C37118IPPort       TPredefinedPTypeEnum = "C37-118-IP-Port"
	TPredefinedPTypeEnum_IPUDPPORT          TPredefinedPTypeEnum = "IP-UDP-PORT"
	TPredefinedPTypeEnum_IPTCPPORT          TPredefinedPTypeEnum = "IP-TCP-PORT"
	TPredefinedPTypeEnum_IPv6               TPredefinedPTypeEnum = "IPv6"
	TPredefinedPTypeEnum_IPv6SUBNET         TPredefinedPTypeEnum = "IPv6-SUBNET"
	TPredefinedPTypeEnum_IPv6GATEWAY        TPredefinedPTypeEnum = "IPv6-GATEWAY"
	TPredefinedPTypeEnum_IPv6IGMPv3Src      TPredefinedPTypeEnum = "IPv6-IGMPv3Src"
	TPredefinedPTypeEnum_IPIGMPv3Src        TPredefinedPTypeEnum = "IP-IGMPv3Src"
	TPredefinedPTypeEnum_IPClassOfTraffic   TPredefinedPTypeEnum = "IP-ClassOfTraffic"
)

func (*TPredefinedPTypeEnum) Validate

func (t *TPredefinedPTypeEnum) Validate() error

type TRestrName1stL

type TRestrName1stL string

"SimpleType" base:"xs:Name" TRestrName1stL ...

func (*TRestrName1stL) Validate

func (t *TRestrName1stL) Validate() error

type TSDOCount

type TSDOCount struct {
	Content string `xml:",chardata" json:",omitempty"`
	// contains filtered or unexported fields
}

"SimpleType" TSDOCount is UNION type

func (*TSDOCount) IsEmpty

func (t *TSDOCount) IsEmpty() bool

func (*TSDOCount) MarshalXMLAttr

func (t *TSDOCount) MarshalXMLAttr(name xml.Name) (xml.Attr, error)

func (*TSDOCount) UnmarshalXMLAttr

func (t *TSDOCount) UnmarshalXMLAttr(attr xml.Attr) error

func (*TSDOCount) Validate

func (t *TSDOCount) Validate() error

type TVal

type TVal struct {
	NodeID
	Content    string  `xml:",chardata" json:",omitempty"`
	SGroupAttr *uint32 `xml:"sGroup,attr,omitempty" json:"sGroup,omitempty"`
}

"ComplexType" TVal ...

func (*TVal) Validate

func (t *TVal) Validate() error

type UnsignedInt

type UnsignedInt string

func (*UnsignedInt) Validate

func (u *UnsignedInt) Validate() error

type Val

type Val = TVal

"Element" Val ...

type Validator

type Validator interface {
	Validate() error
}

Jump to

Keyboard shortcuts

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