type_bytes.go 576 Bytes
Newer Older
1 2 3
package schema

import (
tavit ohanian's avatar
tavit ohanian committed
4
	ld "gitlab.dms3.io/ld/go-ld-prime"
tavit ohanian's avatar
tavit ohanian committed
5
	schemadmt "gitlab.dms3.io/ld/go-ld-prime/schema/dmt"
6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
)

type TypeBytes struct {
	name TypeName
	dmt  schemadmt.TypeBytes
	ts   *TypeSystem
}

// -- schema.Type interface satisfaction -->

var _ Type = (*TypeBytes)(nil)

func (t *TypeBytes) _Type() {}

func (t *TypeBytes) TypeSystem() *TypeSystem {
	return t.ts
}

24 25
func (TypeBytes) TypeKind() TypeKind {
	return TypeKind_Bytes
26 27 28 29 30 31
}

func (t *TypeBytes) Name() TypeName {
	return t.name
}

tavit ohanian's avatar
tavit ohanian committed
32 33
func (t TypeBytes) RepresentationBehavior() ld.Kind {
	return ld.Kind_Bytes
34
}