Documentation ¶
Index ¶
- func CompletePath(prefix, path *sdcpb.Path) ([]string, error)
- func CompletePathFromString(s string) ([]string, error)
- func Convert(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
- func ConvertBinary(value string, slt *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
- func ConvertBoolean(value string, _ *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
- func ConvertDecimal64(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
- func ConvertEnumeration(value string, slt *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
- func ConvertIdentityRef(value string, slt *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
- func ConvertInstanceIdentifier(value string, slt *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
- func ConvertInt16(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
- func ConvertInt32(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
- func ConvertInt64(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
- func ConvertInt8(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
- func ConvertLeafRef(value string, slt *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
- func ConvertSdcpbNumberToInt64(mm *sdcpb.Number) (int64, error)
- func ConvertSdcpbNumberToUint64(mm *sdcpb.Number) (uint64, error)
- func ConvertString(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
- func ConvertUint16(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
- func ConvertUint32(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
- func ConvertUint64(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
- func ConvertUint8(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
- func ConvertUnion(value string, slts []*sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
- func CopyMap(m map[string]string) map[string]string
- func CopyPath(p *sdcpb.Path) *sdcpb.Path
- func EqualTypedValues(v1, v2 *sdcpb.TypedValue) bool
- func FromGNMIPath(pre, p *gnmi.Path) *sdcpb.Path
- func FromGNMITypedValue(v *gnmi.TypedValue) *sdcpb.TypedValue
- func GetSchemaValue(updValue *sdcpb.TypedValue) (interface{}, error)
- func GetValue(updValue *gnmi.TypedValue) (interface{}, error)
- func NotificationsEqual(n1, n2 *sdcpb.Notification) bool
- func ParseDecimal64(v string) (*sdcpb.Decimal64, error)
- func ParsePath(p string) (*sdcpb.Path, error)
- func PathsEqual(p1, p2 *sdcpb.Path) bool
- func StripPathElemPrefix(p string) (string, error)
- func ToGNMIPath(p *sdcpb.Path) *gnmi.Path
- func ToGNMITypedValue(v *sdcpb.TypedValue) *gnmi.TypedValue
- func ToSchemaNotification(n *gnmi.Notification) *sdcpb.Notification
- func ToSchemaTypedValue(v any) *sdcpb.TypedValue
- func ToStrings(p *sdcpb.Path, prefix, nokeys bool) []string
- func ToXPath(p *sdcpb.Path, noKeys bool) string
- func TypedValueToString(tv *sdcpb.TypedValue) string
- type SRng
- type SRnges
- type URng
- type URnges
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CompletePathFromString ¶
func Convert ¶ added in v0.0.42
func Convert(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
func ConvertBinary ¶ added in v0.0.42
func ConvertBinary(value string, slt *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
func ConvertBoolean ¶ added in v0.0.42
func ConvertBoolean(value string, _ *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
func ConvertDecimal64 ¶ added in v0.0.42
func ConvertDecimal64(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
func ConvertEnumeration ¶ added in v0.0.42
func ConvertEnumeration(value string, slt *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
func ConvertIdentityRef ¶ added in v0.0.42
func ConvertIdentityRef(value string, slt *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
func ConvertInstanceIdentifier ¶ added in v0.0.42
func ConvertInstanceIdentifier(value string, slt *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
func ConvertInt16 ¶ added in v0.0.42
func ConvertInt16(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
func ConvertInt32 ¶ added in v0.0.42
func ConvertInt32(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
func ConvertInt64 ¶ added in v0.0.42
func ConvertInt64(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
func ConvertInt8 ¶ added in v0.0.42
func ConvertInt8(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
func ConvertLeafRef ¶ added in v0.0.42
func ConvertLeafRef(value string, slt *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
func ConvertSdcpbNumberToInt64 ¶ added in v0.0.42
func ConvertSdcpbNumberToUint64 ¶ added in v0.0.42
func ConvertString ¶ added in v0.0.42
func ConvertString(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
func ConvertUint16 ¶ added in v0.0.42
func ConvertUint16(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
func ConvertUint32 ¶ added in v0.0.42
func ConvertUint32(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
func ConvertUint64 ¶ added in v0.0.42
func ConvertUint64(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
func ConvertUint8 ¶ added in v0.0.42
func ConvertUint8(value string, lst *sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
func ConvertUnion ¶ added in v0.0.42
func ConvertUnion(value string, slts []*sdcpb.SchemaLeafType) (*sdcpb.TypedValue, error)
func EqualTypedValues ¶
func EqualTypedValues(v1, v2 *sdcpb.TypedValue) bool
func FromGNMITypedValue ¶
func FromGNMITypedValue(v *gnmi.TypedValue) *sdcpb.TypedValue
func GetSchemaValue ¶
func GetSchemaValue(updValue *sdcpb.TypedValue) (interface{}, error)
func GetValue ¶
func GetValue(updValue *gnmi.TypedValue) (interface{}, error)
func NotificationsEqual ¶
func NotificationsEqual(n1, n2 *sdcpb.Notification) bool
func ParsePath ¶
ParsePath creates a sdcpb.Path out of a p string, check if the first element is prefixed by an origin, removes it from the xpath and adds it to the returned sdcpb.Path
func PathsEqual ¶
func StripPathElemPrefix ¶
func ToGNMITypedValue ¶
func ToGNMITypedValue(v *sdcpb.TypedValue) *gnmi.TypedValue
func ToSchemaNotification ¶
func ToSchemaNotification(n *gnmi.Notification) *sdcpb.Notification
func ToSchemaTypedValue ¶
func ToSchemaTypedValue(v any) *sdcpb.TypedValue
func ToStrings ¶
ToStrings converts gnmi.Path to index strings. When index strings are generated, gnmi.Path will be irreversibly lost. Index strings will be built by using name field in gnmi.PathElem. If gnmi.PathElem has key field, values will be included in alphabetical order of the keys. E.g. <target>/<origin>/a/b[b:d, a:c]/e will be returned as <target>/<origin>/a/b/c/d/e If prefix parameter is set to true, <target> and <origin> fields of the gnmi.Path will be prepended in the index strings unless they are empty string. gnmi.Path.Element field is deprecated, but being gracefully handled by this function in the absence of gnmi.Path.Elem.
func TypedValueToString ¶
func TypedValueToString(tv *sdcpb.TypedValue) string
Types ¶
type SRng ¶ added in v0.0.42
type SRng struct {
// contains filtered or unexported fields
}
urng represents a single unsigned range
type SRnges ¶ added in v0.0.42
type SRnges struct {
// contains filtered or unexported fields
}
urnges represents a collection of rng (range)