models/object.go
func NewObject(name string, t string, st string, content []byte) *Object {
	if len(content) > MaxObjectContentLen {
		content = content[:MaxObjectContentLen]
	}
	o := &Object{
		Type: t,
		SubType: st,

		Name:    name,
		Content: content,

		Metadata:       make(map[string]MetadataData),
		PrimaryKeyHash: nil,
	}
	return o
}
func NewObject(name string, t string, st string, content []byte) *Object {
	if len(content) > MaxObjectContentLen {
		content = content[:MaxObjectContentLen]
	}
	o := &Object{
		Type: t,
		SubType: st,

		Name:    name,
		Content: content,

		Metadata:       make(map[string]MetadataData),
		PrimaryKeyHash: nil,
	}
	return o
}
// NewObject creates a new object.