resource_model

package
v1.1.45 Latest Latest
Warning

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

Go to latest
Published: Sep 9, 2023 License: MIT Imports: 8 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DataSourceMapperInstance = NewDataSourceMapper()
View Source
var ExtensionBooleanExpressionMapperInstance = NewExtensionBooleanExpressionMapper()
View Source
var ExtensionEventMapperInstance = NewExtensionEventMapper()
View Source
var ExtensionEventSelectorMapperInstance = NewExtensionEventSelectorMapper()
View Source
var ExtensionExternalCallMapperInstance = NewExtensionExternalCallMapper()
View Source
var ExtensionFunctionCallMapperInstance = NewExtensionFunctionCallMapper()
View Source
var ExtensionHttpCallMapperInstance = NewExtensionHttpCallMapper()
View Source
var ExtensionMapperInstance = NewExtensionMapper()
View Source
var ExtensionRecordSearchParamsMapperInstance = NewExtensionRecordSearchParamsMapper()
View Source
var NamespaceMapperInstance = NewNamespaceMapper()
View Source
var PermissionMapperInstance = NewPermissionMapper()
View Source
var RecordMapperInstance = NewRecordMapper()
View Source
var ResourceIndexMapperInstance = NewResourceIndexMapper()
View Source
var ResourceIndexPropertyMapperInstance = NewResourceIndexPropertyMapper()
View Source
var ResourceMapperInstance = NewResourceMapper()
View Source
var ResourcePropertyMapperInstance = NewResourcePropertyMapper()
View Source
var ResourceReferenceMapperInstance = NewResourceReferenceMapper()
View Source
var ResourceSubTypeMapperInstance = NewResourceSubTypeMapper()
View Source
var RoleMapperInstance = NewRoleMapper()
View Source
var UserMapperInstance = NewUserMapper()

Functions

This section is empty.

Types

type DataSource

type DataSource struct {
	Id          *uuid.UUID        `json:"id,omitempty"`
	Version     int32             `json:"version,omitempty"`
	CreatedBy   *string           `json:"createdBy,omitempty"`
	UpdatedBy   *string           `json:"updatedBy,omitempty"`
	CreatedOn   *time.Time        `json:"createdOn,omitempty"`
	UpdatedOn   *time.Time        `json:"updatedOn,omitempty"`
	Name        string            `json:"name,omitempty"`
	Description string            `json:"description,omitempty"`
	Backend     DataSourceBackend `json:"backend,omitempty"`
	Options     map[string]string `json:"options,omitempty"`
}

func (*DataSource) GetBackend

func (s *DataSource) GetBackend() DataSourceBackend

func (*DataSource) GetCreatedBy

func (s *DataSource) GetCreatedBy() *string

func (*DataSource) GetCreatedOn

func (s *DataSource) GetCreatedOn() *time.Time

func (*DataSource) GetDescription

func (s *DataSource) GetDescription() string

func (*DataSource) GetId

func (s *DataSource) GetId() *uuid.UUID

func (*DataSource) GetName

func (s *DataSource) GetName() string

func (*DataSource) GetOptions

func (s *DataSource) GetOptions() map[string]string

func (*DataSource) GetUpdatedBy

func (s *DataSource) GetUpdatedBy() *string

func (*DataSource) GetUpdatedOn

func (s *DataSource) GetUpdatedOn() *time.Time

func (*DataSource) GetVersion

func (s *DataSource) GetVersion() int32

type DataSourceBackend

type DataSourceBackend string
const (
	DataSourceBackend_POSTGRESQL DataSourceBackend = "POSTGRESQL"
	DataSourceBackend_MYSQL      DataSourceBackend = "MYSQL"
	DataSourceBackend_MONGODB    DataSourceBackend = "MONGODB"
	DataSourceBackend_REDIS      DataSourceBackend = "REDIS"
)

type DataSourceMapper

type DataSourceMapper struct {
}

func NewDataSourceMapper

func NewDataSourceMapper() *DataSourceMapper

func (*DataSourceMapper) FromProperties

func (m *DataSourceMapper) FromProperties(properties map[string]*structpb.Value) *DataSource

func (*DataSourceMapper) FromRecord

func (m *DataSourceMapper) FromRecord(record *model.Record) *DataSource

func (*DataSourceMapper) New

func (m *DataSourceMapper) New() *DataSource

func (*DataSourceMapper) ResourceIdentity

func (m *DataSourceMapper) ResourceIdentity() abs.ResourceIdentity

func (*DataSourceMapper) ToProperties

func (m *DataSourceMapper) ToProperties(dataSource *DataSource) map[string]*structpb.Value

func (*DataSourceMapper) ToRecord

func (m *DataSourceMapper) ToRecord(dataSource *DataSource) *model.Record

type EventAction

type EventAction string
const (
	EventAction_CREATE  EventAction = "CREATE"
	EventAction_UPDATE  EventAction = "UPDATE"
	EventAction_DELETE  EventAction = "DELETE"
	EventAction_GET     EventAction = "GET"
	EventAction_LIST    EventAction = "LIST"
	EventAction_OPERATE EventAction = "OPERATE"
)

type Extension

type Extension struct {
	Id          *uuid.UUID              `json:"id,omitempty"`
	Version     int32                   `json:"version,omitempty"`
	CreatedBy   *string                 `json:"createdBy,omitempty"`
	UpdatedBy   *string                 `json:"updatedBy,omitempty"`
	CreatedOn   *time.Time              `json:"createdOn,omitempty"`
	UpdatedOn   *time.Time              `json:"updatedOn,omitempty"`
	Name        string                  `json:"name,omitempty"`
	Description *string                 `json:"description,omitempty"`
	Selector    *ExtensionEventSelector `json:"selector,omitempty"`
	Order       int32                   `json:"order,omitempty"`
	Finalizes   bool                    `json:"finalizes,omitempty"`
	Sync        bool                    `json:"sync,omitempty"`
	Responds    bool                    `json:"responds,omitempty"`
	Call        ExtensionExternalCall   `json:"call,omitempty"`
	Annotations map[string]string       `json:"annotations,omitempty"`
}

func (*Extension) GetAnnotations

func (s *Extension) GetAnnotations() map[string]string

func (*Extension) GetCall

func (s *Extension) GetCall() ExtensionExternalCall

func (*Extension) GetCreatedBy

func (s *Extension) GetCreatedBy() *string

func (*Extension) GetCreatedOn

func (s *Extension) GetCreatedOn() *time.Time

func (*Extension) GetDescription

func (s *Extension) GetDescription() *string

func (*Extension) GetFinalizes

func (s *Extension) GetFinalizes() bool

func (*Extension) GetId

func (s *Extension) GetId() *uuid.UUID

func (*Extension) GetName

func (s *Extension) GetName() string

func (*Extension) GetOrder

func (s *Extension) GetOrder() int32

func (*Extension) GetResponds

func (s *Extension) GetResponds() bool

func (*Extension) GetSelector

func (s *Extension) GetSelector() *ExtensionEventSelector

func (*Extension) GetSync

func (s *Extension) GetSync() bool

func (*Extension) GetUpdatedBy

func (s *Extension) GetUpdatedBy() *string

func (*Extension) GetUpdatedOn

func (s *Extension) GetUpdatedOn() *time.Time

func (*Extension) GetVersion

func (s *Extension) GetVersion() int32

type ExtensionBooleanExpression

type ExtensionBooleanExpression struct {
}

type ExtensionBooleanExpressionMapper

type ExtensionBooleanExpressionMapper struct {
}

func NewExtensionBooleanExpressionMapper

func NewExtensionBooleanExpressionMapper() *ExtensionBooleanExpressionMapper

func (*ExtensionBooleanExpressionMapper) FromProperties

func (*ExtensionBooleanExpressionMapper) New

func (*ExtensionBooleanExpressionMapper) ResourceIdentity

func (*ExtensionBooleanExpressionMapper) ToProperties

func (m *ExtensionBooleanExpressionMapper) ToProperties(extensionBooleanExpression *ExtensionBooleanExpression) map[string]*structpb.Value

type ExtensionEvent

type ExtensionEvent struct {
	Id                 *uuid.UUID                   `json:"id,omitempty"`
	Action             EventAction                  `json:"action,omitempty"`
	RecordSearchParams *ExtensionRecordSearchParams `json:"recordSearchParams,omitempty"`
	ActionSummary      *string                      `json:"actionSummary,omitempty"`
	ActionDescription  *string                      `json:"actionDescription,omitempty"`
	Resource           *Resource                    `json:"resource,omitempty"`
	Records            []*Record                    `json:"records,omitempty"`
	Ids                []string                     `json:"ids,omitempty"`
	Finalizes          *bool                        `json:"finalizes,omitempty"`
	Sync               *bool                        `json:"sync,omitempty"`
	Time               *time.Time                   `json:"time,omitempty"`
	Annotations        map[string]string            `json:"annotations,omitempty"`
}

func (*ExtensionEvent) GetAction

func (s *ExtensionEvent) GetAction() EventAction

func (*ExtensionEvent) GetActionDescription

func (s *ExtensionEvent) GetActionDescription() *string

func (*ExtensionEvent) GetActionSummary

func (s *ExtensionEvent) GetActionSummary() *string

func (*ExtensionEvent) GetAnnotations

func (s *ExtensionEvent) GetAnnotations() map[string]string

func (*ExtensionEvent) GetFinalizes

func (s *ExtensionEvent) GetFinalizes() *bool

func (*ExtensionEvent) GetId

func (s *ExtensionEvent) GetId() *uuid.UUID

func (*ExtensionEvent) GetIds

func (s *ExtensionEvent) GetIds() []string

func (*ExtensionEvent) GetRecordSearchParams

func (s *ExtensionEvent) GetRecordSearchParams() *ExtensionRecordSearchParams

func (*ExtensionEvent) GetRecords

func (s *ExtensionEvent) GetRecords() []*Record

func (*ExtensionEvent) GetResource

func (s *ExtensionEvent) GetResource() *Resource

func (*ExtensionEvent) GetSync

func (s *ExtensionEvent) GetSync() *bool

func (*ExtensionEvent) GetTime

func (s *ExtensionEvent) GetTime() *time.Time

type ExtensionEventMapper

type ExtensionEventMapper struct {
}

func NewExtensionEventMapper

func NewExtensionEventMapper() *ExtensionEventMapper

func (*ExtensionEventMapper) FromProperties

func (m *ExtensionEventMapper) FromProperties(properties map[string]*structpb.Value) *ExtensionEvent

func (*ExtensionEventMapper) New

func (*ExtensionEventMapper) ResourceIdentity

func (m *ExtensionEventMapper) ResourceIdentity() abs.ResourceIdentity

func (*ExtensionEventMapper) ToProperties

func (m *ExtensionEventMapper) ToProperties(extensionEvent *ExtensionEvent) map[string]*structpb.Value

type ExtensionEventSelector

type ExtensionEventSelector struct {
	Actions        []EventAction               `json:"actions,omitempty"`
	RecordSelector *ExtensionBooleanExpression `json:"recordSelector,omitempty"`
	Namespaces     []string                    `json:"namespaces,omitempty"`
	Resources      []string                    `json:"resources,omitempty"`
	Ids            []string                    `json:"ids,omitempty"`
	Annotations    map[string]string           `json:"annotations,omitempty"`
}

func (*ExtensionEventSelector) GetActions

func (s *ExtensionEventSelector) GetActions() []EventAction

func (*ExtensionEventSelector) GetAnnotations

func (s *ExtensionEventSelector) GetAnnotations() map[string]string

func (*ExtensionEventSelector) GetIds

func (s *ExtensionEventSelector) GetIds() []string

func (*ExtensionEventSelector) GetNamespaces

func (s *ExtensionEventSelector) GetNamespaces() []string

func (*ExtensionEventSelector) GetRecordSelector

func (s *ExtensionEventSelector) GetRecordSelector() *ExtensionBooleanExpression

func (*ExtensionEventSelector) GetResources

func (s *ExtensionEventSelector) GetResources() []string

type ExtensionEventSelectorMapper

type ExtensionEventSelectorMapper struct {
}

func NewExtensionEventSelectorMapper

func NewExtensionEventSelectorMapper() *ExtensionEventSelectorMapper

func (*ExtensionEventSelectorMapper) FromProperties

func (m *ExtensionEventSelectorMapper) FromProperties(properties map[string]*structpb.Value) *ExtensionEventSelector

func (*ExtensionEventSelectorMapper) New

func (*ExtensionEventSelectorMapper) ResourceIdentity

func (m *ExtensionEventSelectorMapper) ResourceIdentity() abs.ResourceIdentity

func (*ExtensionEventSelectorMapper) ToProperties

func (m *ExtensionEventSelectorMapper) ToProperties(extensionEventSelector *ExtensionEventSelector) map[string]*structpb.Value

type ExtensionExternalCall

type ExtensionExternalCall struct {
	FunctionCall *ExtensionFunctionCall `json:"functionCall,omitempty"`
	HttpCall     *ExtensionHttpCall     `json:"httpCall,omitempty"`
}

func (*ExtensionExternalCall) GetFunctionCall

func (s *ExtensionExternalCall) GetFunctionCall() *ExtensionFunctionCall

func (*ExtensionExternalCall) GetHttpCall

func (s *ExtensionExternalCall) GetHttpCall() *ExtensionHttpCall

type ExtensionExternalCallMapper

type ExtensionExternalCallMapper struct {
}

func NewExtensionExternalCallMapper

func NewExtensionExternalCallMapper() *ExtensionExternalCallMapper

func (*ExtensionExternalCallMapper) FromProperties

func (m *ExtensionExternalCallMapper) FromProperties(properties map[string]*structpb.Value) *ExtensionExternalCall

func (*ExtensionExternalCallMapper) New

func (*ExtensionExternalCallMapper) ResourceIdentity

func (m *ExtensionExternalCallMapper) ResourceIdentity() abs.ResourceIdentity

func (*ExtensionExternalCallMapper) ToProperties

func (m *ExtensionExternalCallMapper) ToProperties(extensionExternalCall *ExtensionExternalCall) map[string]*structpb.Value

type ExtensionFunctionCall

type ExtensionFunctionCall struct {
	Host         string `json:"host,omitempty"`
	FunctionName string `json:"functionName,omitempty"`
}

func (*ExtensionFunctionCall) GetFunctionName

func (s *ExtensionFunctionCall) GetFunctionName() string

func (*ExtensionFunctionCall) GetHost

func (s *ExtensionFunctionCall) GetHost() string

type ExtensionFunctionCallMapper

type ExtensionFunctionCallMapper struct {
}

func NewExtensionFunctionCallMapper

func NewExtensionFunctionCallMapper() *ExtensionFunctionCallMapper

func (*ExtensionFunctionCallMapper) FromProperties

func (m *ExtensionFunctionCallMapper) FromProperties(properties map[string]*structpb.Value) *ExtensionFunctionCall

func (*ExtensionFunctionCallMapper) New

func (*ExtensionFunctionCallMapper) ResourceIdentity

func (m *ExtensionFunctionCallMapper) ResourceIdentity() abs.ResourceIdentity

func (*ExtensionFunctionCallMapper) ToProperties

func (m *ExtensionFunctionCallMapper) ToProperties(extensionFunctionCall *ExtensionFunctionCall) map[string]*structpb.Value

type ExtensionHttpCall

type ExtensionHttpCall struct {
	Uri    string `json:"uri,omitempty"`
	Method string `json:"method,omitempty"`
}

func (*ExtensionHttpCall) GetMethod

func (s *ExtensionHttpCall) GetMethod() string

func (*ExtensionHttpCall) GetUri

func (s *ExtensionHttpCall) GetUri() string

type ExtensionHttpCallMapper

type ExtensionHttpCallMapper struct {
}

func NewExtensionHttpCallMapper

func NewExtensionHttpCallMapper() *ExtensionHttpCallMapper

func (*ExtensionHttpCallMapper) FromProperties

func (m *ExtensionHttpCallMapper) FromProperties(properties map[string]*structpb.Value) *ExtensionHttpCall

func (*ExtensionHttpCallMapper) New

func (*ExtensionHttpCallMapper) ResourceIdentity

func (m *ExtensionHttpCallMapper) ResourceIdentity() abs.ResourceIdentity

func (*ExtensionHttpCallMapper) ToProperties

func (m *ExtensionHttpCallMapper) ToProperties(extensionHttpCall *ExtensionHttpCall) map[string]*structpb.Value

type ExtensionMapper

type ExtensionMapper struct {
}

func NewExtensionMapper

func NewExtensionMapper() *ExtensionMapper

func (*ExtensionMapper) FromProperties

func (m *ExtensionMapper) FromProperties(properties map[string]*structpb.Value) *Extension

func (*ExtensionMapper) FromRecord

func (m *ExtensionMapper) FromRecord(record *model.Record) *Extension

func (*ExtensionMapper) New

func (m *ExtensionMapper) New() *Extension

func (*ExtensionMapper) ResourceIdentity

func (m *ExtensionMapper) ResourceIdentity() abs.ResourceIdentity

func (*ExtensionMapper) ToProperties

func (m *ExtensionMapper) ToProperties(extension *Extension) map[string]*structpb.Value

func (*ExtensionMapper) ToRecord

func (m *ExtensionMapper) ToRecord(extension *Extension) *model.Record

type ExtensionRecordSearchParams

type ExtensionRecordSearchParams struct {
	Query             *ExtensionBooleanExpression `json:"query,omitempty"`
	Limit             *int32                      `json:"limit,omitempty"`
	Offset            *int32                      `json:"offset,omitempty"`
	ResolveReferences []string                    `json:"resolveReferences,omitempty"`
}

func (*ExtensionRecordSearchParams) GetLimit

func (s *ExtensionRecordSearchParams) GetLimit() *int32

func (*ExtensionRecordSearchParams) GetOffset

func (s *ExtensionRecordSearchParams) GetOffset() *int32

func (*ExtensionRecordSearchParams) GetQuery

func (*ExtensionRecordSearchParams) GetResolveReferences

func (s *ExtensionRecordSearchParams) GetResolveReferences() []string

type ExtensionRecordSearchParamsMapper

type ExtensionRecordSearchParamsMapper struct {
}

func NewExtensionRecordSearchParamsMapper

func NewExtensionRecordSearchParamsMapper() *ExtensionRecordSearchParamsMapper

func (*ExtensionRecordSearchParamsMapper) FromProperties

func (*ExtensionRecordSearchParamsMapper) New

func (*ExtensionRecordSearchParamsMapper) ResourceIdentity

func (*ExtensionRecordSearchParamsMapper) ToProperties

func (m *ExtensionRecordSearchParamsMapper) ToProperties(extensionRecordSearchParams *ExtensionRecordSearchParams) map[string]*structpb.Value

type Namespace

type Namespace struct {
	Id          *uuid.UUID                 `json:"id,omitempty"`
	Version     int32                      `json:"version,omitempty"`
	CreatedBy   *string                    `json:"createdBy,omitempty"`
	UpdatedBy   *string                    `json:"updatedBy,omitempty"`
	CreatedOn   *time.Time                 `json:"createdOn,omitempty"`
	UpdatedOn   *time.Time                 `json:"updatedOn,omitempty"`
	Name        string                     `json:"name,omitempty"`
	Description *string                    `json:"description,omitempty"`
	Details     *unstructured.Unstructured `json:"details,omitempty"`
}

func (*Namespace) GetCreatedBy

func (s *Namespace) GetCreatedBy() *string

func (*Namespace) GetCreatedOn

func (s *Namespace) GetCreatedOn() *time.Time

func (*Namespace) GetDescription

func (s *Namespace) GetDescription() *string

func (*Namespace) GetDetails

func (s *Namespace) GetDetails() *unstructured.Unstructured

func (*Namespace) GetId

func (s *Namespace) GetId() *uuid.UUID

func (*Namespace) GetName

func (s *Namespace) GetName() string

func (*Namespace) GetUpdatedBy

func (s *Namespace) GetUpdatedBy() *string

func (*Namespace) GetUpdatedOn

func (s *Namespace) GetUpdatedOn() *time.Time

func (*Namespace) GetVersion

func (s *Namespace) GetVersion() int32

type NamespaceMapper

type NamespaceMapper struct {
}

func NewNamespaceMapper

func NewNamespaceMapper() *NamespaceMapper

func (*NamespaceMapper) FromProperties

func (m *NamespaceMapper) FromProperties(properties map[string]*structpb.Value) *Namespace

func (*NamespaceMapper) FromRecord

func (m *NamespaceMapper) FromRecord(record *model.Record) *Namespace

func (*NamespaceMapper) New

func (m *NamespaceMapper) New() *Namespace

func (*NamespaceMapper) ResourceIdentity

func (m *NamespaceMapper) ResourceIdentity() abs.ResourceIdentity

func (*NamespaceMapper) ToProperties

func (m *NamespaceMapper) ToProperties(namespace *Namespace) map[string]*structpb.Value

func (*NamespaceMapper) ToRecord

func (m *NamespaceMapper) ToRecord(namespace *Namespace) *model.Record

type Permission added in v1.1.40

type Permission struct {
	Id            *uuid.UUID                 `json:"id,omitempty"`
	Version       int32                      `json:"version,omitempty"`
	CreatedBy     *string                    `json:"createdBy,omitempty"`
	UpdatedBy     *string                    `json:"updatedBy,omitempty"`
	CreatedOn     *time.Time                 `json:"createdOn,omitempty"`
	UpdatedOn     *time.Time                 `json:"updatedOn,omitempty"`
	Namespace     *string                    `json:"namespace,omitempty"`
	Resource      *string                    `json:"resource,omitempty"`
	Property      *string                    `json:"property,omitempty"`
	PropertyValue *string                    `json:"propertyValue,omitempty"`
	PropertyMode  *PermissionPropertyMode    `json:"propertyMode,omitempty"`
	Operation     PermissionOperation        `json:"operation,omitempty"`
	RecordIds     []string                   `json:"recordIds,omitempty"`
	Before        *time.Time                 `json:"before,omitempty"`
	After         *time.Time                 `json:"after,omitempty"`
	User          *User                      `json:"user,omitempty"`
	Role          *Role                      `json:"role,omitempty"`
	Permit        PermissionPermit           `json:"permit,omitempty"`
	LocalFlags    *unstructured.Unstructured `json:"localFlags,omitempty"`
}

func (*Permission) GetAfter added in v1.1.40

func (s *Permission) GetAfter() *time.Time

func (*Permission) GetBefore added in v1.1.40

func (s *Permission) GetBefore() *time.Time

func (*Permission) GetCreatedBy added in v1.1.40

func (s *Permission) GetCreatedBy() *string

func (*Permission) GetCreatedOn added in v1.1.40

func (s *Permission) GetCreatedOn() *time.Time

func (*Permission) GetId added in v1.1.40

func (s *Permission) GetId() *uuid.UUID

func (*Permission) GetLocalFlags added in v1.1.40

func (s *Permission) GetLocalFlags() *unstructured.Unstructured

func (*Permission) GetNamespace added in v1.1.40

func (s *Permission) GetNamespace() *string

func (*Permission) GetOperation added in v1.1.40

func (s *Permission) GetOperation() PermissionOperation

func (*Permission) GetPermit added in v1.1.40

func (s *Permission) GetPermit() PermissionPermit

func (*Permission) GetProperty added in v1.1.40

func (s *Permission) GetProperty() *string

func (*Permission) GetPropertyMode added in v1.1.40

func (s *Permission) GetPropertyMode() *PermissionPropertyMode

func (*Permission) GetPropertyValue added in v1.1.40

func (s *Permission) GetPropertyValue() *string

func (*Permission) GetRecordIds added in v1.1.40

func (s *Permission) GetRecordIds() []string

func (*Permission) GetResource added in v1.1.40

func (s *Permission) GetResource() *string

func (*Permission) GetRole added in v1.1.40

func (s *Permission) GetRole() *Role

func (*Permission) GetUpdatedBy added in v1.1.40

func (s *Permission) GetUpdatedBy() *string

func (*Permission) GetUpdatedOn added in v1.1.40

func (s *Permission) GetUpdatedOn() *time.Time

func (*Permission) GetUser added in v1.1.40

func (s *Permission) GetUser() *User

func (*Permission) GetVersion added in v1.1.40

func (s *Permission) GetVersion() int32

type PermissionMapper added in v1.1.44

type PermissionMapper struct {
}

func NewPermissionMapper added in v1.1.44

func NewPermissionMapper() *PermissionMapper

func (*PermissionMapper) FromProperties added in v1.1.44

func (m *PermissionMapper) FromProperties(properties map[string]*structpb.Value) *Permission

func (*PermissionMapper) FromRecord added in v1.1.44

func (m *PermissionMapper) FromRecord(record *model.Record) *Permission

func (*PermissionMapper) New added in v1.1.44

func (m *PermissionMapper) New() *Permission

func (*PermissionMapper) ResourceIdentity added in v1.1.44

func (m *PermissionMapper) ResourceIdentity() abs.ResourceIdentity

func (*PermissionMapper) ToProperties added in v1.1.44

func (m *PermissionMapper) ToProperties(permission *Permission) map[string]*structpb.Value

func (*PermissionMapper) ToRecord added in v1.1.44

func (m *PermissionMapper) ToRecord(permission *Permission) *model.Record

type PermissionOperation added in v1.1.44

type PermissionOperation string
const (
	PermissionOperation_READ   PermissionOperation = "READ"
	PermissionOperation_CREATE PermissionOperation = "CREATE"
	PermissionOperation_UPDATE PermissionOperation = "UPDATE"
	PermissionOperation_DELETE PermissionOperation = "DELETE"
	PermissionOperation_FULL   PermissionOperation = "FULL"
)

type PermissionPermit added in v1.1.44

type PermissionPermit string
const (
	PermissionPermit_ALLOW  PermissionPermit = "ALLOW"
	PermissionPermit_REJECT PermissionPermit = "REJECT"
)

type PermissionPropertyMode added in v1.1.44

type PermissionPropertyMode string
const (
	PermissionPropertyMode_PROPERTYMATCHONLY PermissionPropertyMode = "PROPERTY_MATCH_ONLY"
	PermissionPropertyMode_PROPERTYMATCHANY  PermissionPropertyMode = "PROPERTY_MATCH_ANY"
)

type Record

type Record struct {
	Id               *uuid.UUID                  `json:"id,omitempty"`
	Properties       unstructured.Unstructured   `json:"properties,omitempty"`
	PackedProperties []unstructured.Unstructured `json:"packedProperties,omitempty"`
}

func (*Record) GetId

func (s *Record) GetId() *uuid.UUID

func (*Record) GetPackedProperties

func (s *Record) GetPackedProperties() []unstructured.Unstructured

func (*Record) GetProperties

func (s *Record) GetProperties() unstructured.Unstructured

func (*Record) MarshalJSON

func (s *Record) MarshalJSON() ([]byte, error)

func (*Record) UnmarshalJSON

func (s *Record) UnmarshalJSON(data []byte) error

type RecordMapper

type RecordMapper struct {
}

func NewRecordMapper

func NewRecordMapper() *RecordMapper

func (*RecordMapper) FromProperties

func (m *RecordMapper) FromProperties(properties map[string]*structpb.Value) *Record

func (*RecordMapper) FromRecord

func (m *RecordMapper) FromRecord(record *model.Record) *Record

func (*RecordMapper) New

func (m *RecordMapper) New() *Record

func (*RecordMapper) ResourceIdentity

func (m *RecordMapper) ResourceIdentity() abs.ResourceIdentity

func (*RecordMapper) ToProperties

func (m *RecordMapper) ToProperties(record *Record) map[string]*structpb.Value

func (*RecordMapper) ToRecord

func (m *RecordMapper) ToRecord(record *Record) *model.Record

type Resource

type Resource struct {
	Id              *uuid.UUID         `json:"id,omitempty"`
	Version         int32              `json:"version,omitempty"`
	CreatedBy       *string            `json:"createdBy,omitempty"`
	UpdatedBy       *string            `json:"updatedBy,omitempty"`
	CreatedOn       *time.Time         `json:"createdOn,omitempty"`
	UpdatedOn       *time.Time         `json:"updatedOn,omitempty"`
	Name            string             `json:"name,omitempty"`
	Namespace       *Namespace         `json:"namespace,omitempty"`
	Virtual         bool               `json:"virtual,omitempty"`
	Properties      []ResourceProperty `json:"properties,omitempty"`
	Indexes         []ResourceIndex    `json:"indexes,omitempty"`
	Types           []ResourceSubType  `json:"types,omitempty"`
	Immutable       bool               `json:"immutable,omitempty"`
	Abstract        bool               `json:"abstract,omitempty"`
	CheckReferences bool               `json:"checkReferences,omitempty"`
	DataSource      *DataSource        `json:"dataSource,omitempty"`
	Entity          *string            `json:"entity,omitempty"`
	Catalog         *string            `json:"catalog,omitempty"`
	Title           *string            `json:"title,omitempty"`
	Description     *string            `json:"description,omitempty"`
	Annotations     map[string]string  `json:"annotations,omitempty"`
}

func (*Resource) GetAbstract

func (s *Resource) GetAbstract() bool

func (*Resource) GetAnnotations

func (s *Resource) GetAnnotations() map[string]string

func (*Resource) GetCatalog

func (s *Resource) GetCatalog() *string

func (*Resource) GetCheckReferences

func (s *Resource) GetCheckReferences() bool

func (*Resource) GetCreatedBy

func (s *Resource) GetCreatedBy() *string

func (*Resource) GetCreatedOn

func (s *Resource) GetCreatedOn() *time.Time

func (*Resource) GetDataSource

func (s *Resource) GetDataSource() *DataSource

func (*Resource) GetDescription

func (s *Resource) GetDescription() *string

func (*Resource) GetEntity

func (s *Resource) GetEntity() *string

func (*Resource) GetId

func (s *Resource) GetId() *uuid.UUID

func (*Resource) GetImmutable

func (s *Resource) GetImmutable() bool

func (*Resource) GetIndexes

func (s *Resource) GetIndexes() []ResourceIndex

func (*Resource) GetName

func (s *Resource) GetName() string

func (*Resource) GetNamespace

func (s *Resource) GetNamespace() *Namespace

func (*Resource) GetProperties

func (s *Resource) GetProperties() []ResourceProperty

func (*Resource) GetTitle

func (s *Resource) GetTitle() *string

func (*Resource) GetTypes

func (s *Resource) GetTypes() []ResourceSubType

func (*Resource) GetUpdatedBy

func (s *Resource) GetUpdatedBy() *string

func (*Resource) GetUpdatedOn

func (s *Resource) GetUpdatedOn() *time.Time

func (*Resource) GetVersion

func (s *Resource) GetVersion() int32

func (*Resource) GetVirtual

func (s *Resource) GetVirtual() bool

type ResourceIndex

type ResourceIndex struct {
	Properties  []ResourceIndexProperty `json:"properties,omitempty"`
	IndexType   *ResourceIndexType      `json:"indexType,omitempty"`
	Unique      *bool                   `json:"unique,omitempty"`
	Annotations map[string]string       `json:"annotations,omitempty"`
}

func (*ResourceIndex) GetAnnotations

func (s *ResourceIndex) GetAnnotations() map[string]string

func (*ResourceIndex) GetIndexType

func (s *ResourceIndex) GetIndexType() *ResourceIndexType

func (*ResourceIndex) GetProperties

func (s *ResourceIndex) GetProperties() []ResourceIndexProperty

func (*ResourceIndex) GetUnique

func (s *ResourceIndex) GetUnique() *bool

type ResourceIndexMapper

type ResourceIndexMapper struct {
}

func NewResourceIndexMapper

func NewResourceIndexMapper() *ResourceIndexMapper

func (*ResourceIndexMapper) FromProperties

func (m *ResourceIndexMapper) FromProperties(properties map[string]*structpb.Value) *ResourceIndex

func (*ResourceIndexMapper) New

func (*ResourceIndexMapper) ResourceIdentity

func (m *ResourceIndexMapper) ResourceIdentity() abs.ResourceIdentity

func (*ResourceIndexMapper) ToProperties

func (m *ResourceIndexMapper) ToProperties(resourceIndex *ResourceIndex) map[string]*structpb.Value

type ResourceIndexProperty

type ResourceIndexProperty struct {
	Name  string         `json:"name,omitempty"`
	Order *ResourceOrder `json:"order,omitempty"`
}

func (*ResourceIndexProperty) GetName

func (s *ResourceIndexProperty) GetName() string

func (*ResourceIndexProperty) GetOrder

func (s *ResourceIndexProperty) GetOrder() *ResourceOrder

type ResourceIndexPropertyMapper

type ResourceIndexPropertyMapper struct {
}

func NewResourceIndexPropertyMapper

func NewResourceIndexPropertyMapper() *ResourceIndexPropertyMapper

func (*ResourceIndexPropertyMapper) FromProperties

func (m *ResourceIndexPropertyMapper) FromProperties(properties map[string]*structpb.Value) *ResourceIndexProperty

func (*ResourceIndexPropertyMapper) New

func (*ResourceIndexPropertyMapper) ResourceIdentity

func (m *ResourceIndexPropertyMapper) ResourceIdentity() abs.ResourceIdentity

func (*ResourceIndexPropertyMapper) ToProperties

func (m *ResourceIndexPropertyMapper) ToProperties(resourceIndexProperty *ResourceIndexProperty) map[string]*structpb.Value

type ResourceIndexType

type ResourceIndexType string
const (
	ResourceIndexType_BTREE ResourceIndexType = "BTREE"
	ResourceIndexType_HASH  ResourceIndexType = "HASH"
)

type ResourceMapper

type ResourceMapper struct {
}

func NewResourceMapper

func NewResourceMapper() *ResourceMapper

func (*ResourceMapper) FromProperties

func (m *ResourceMapper) FromProperties(properties map[string]*structpb.Value) *Resource

func (*ResourceMapper) FromRecord

func (m *ResourceMapper) FromRecord(record *model.Record) *Resource

func (*ResourceMapper) New

func (m *ResourceMapper) New() *Resource

func (*ResourceMapper) ResourceIdentity

func (m *ResourceMapper) ResourceIdentity() abs.ResourceIdentity

func (*ResourceMapper) ToProperties

func (m *ResourceMapper) ToProperties(resource *Resource) map[string]*structpb.Value

func (*ResourceMapper) ToRecord

func (m *ResourceMapper) ToRecord(resource *Resource) *model.Record

type ResourceOrder

type ResourceOrder string
const (
	ResourceOrder_UNKNOWN ResourceOrder = "UNKNOWN"
	ResourceOrder_ASC     ResourceOrder = "ASC"
	ResourceOrder_DESC    ResourceOrder = "DESC"
)

type ResourceProperty

type ResourceProperty struct {
	Name         string                     `json:"name,omitempty"`
	Type         ResourceType               `json:"type,omitempty"`
	TypeRef      *string                    `json:"typeRef,omitempty"`
	Mapping      string                     `json:"mapping,omitempty"`
	Primary      bool                       `json:"primary,omitempty"`
	Required     bool                       `json:"required,omitempty"`
	Unique       bool                       `json:"unique,omitempty"`
	Immutable    bool                       `json:"immutable,omitempty"`
	Length       int32                      `json:"length,omitempty"`
	Item         *ResourceProperty          `json:"item,omitempty"`
	Reference    *ResourceReference         `json:"reference,omitempty"`
	DefaultValue *unstructured.Unstructured `json:"defaultValue,omitempty"`
	EnumValues   []string                   `json:"enumValues,omitempty"`
	ExampleValue *unstructured.Unstructured `json:"exampleValue,omitempty"`
	Title        *string                    `json:"title,omitempty"`
	Description  *string                    `json:"description,omitempty"`
	Annotations  map[string]string          `json:"annotations,omitempty"`
}

func (*ResourceProperty) GetAnnotations

func (s *ResourceProperty) GetAnnotations() map[string]string

func (*ResourceProperty) GetDefaultValue

func (s *ResourceProperty) GetDefaultValue() *unstructured.Unstructured

func (*ResourceProperty) GetDescription

func (s *ResourceProperty) GetDescription() *string

func (*ResourceProperty) GetEnumValues

func (s *ResourceProperty) GetEnumValues() []string

func (*ResourceProperty) GetExampleValue

func (s *ResourceProperty) GetExampleValue() *unstructured.Unstructured

func (*ResourceProperty) GetImmutable

func (s *ResourceProperty) GetImmutable() bool

func (*ResourceProperty) GetItem

func (s *ResourceProperty) GetItem() *ResourceProperty

func (*ResourceProperty) GetLength

func (s *ResourceProperty) GetLength() int32

func (*ResourceProperty) GetMapping

func (s *ResourceProperty) GetMapping() string

func (*ResourceProperty) GetName

func (s *ResourceProperty) GetName() string

func (*ResourceProperty) GetPrimary

func (s *ResourceProperty) GetPrimary() bool

func (*ResourceProperty) GetReference

func (s *ResourceProperty) GetReference() *ResourceReference

func (*ResourceProperty) GetRequired

func (s *ResourceProperty) GetRequired() bool

func (*ResourceProperty) GetTitle

func (s *ResourceProperty) GetTitle() *string

func (*ResourceProperty) GetType

func (s *ResourceProperty) GetType() ResourceType

func (*ResourceProperty) GetTypeRef

func (s *ResourceProperty) GetTypeRef() *string

func (*ResourceProperty) GetUnique

func (s *ResourceProperty) GetUnique() bool

type ResourcePropertyMapper

type ResourcePropertyMapper struct {
}

func NewResourcePropertyMapper

func NewResourcePropertyMapper() *ResourcePropertyMapper

func (*ResourcePropertyMapper) FromProperties

func (m *ResourcePropertyMapper) FromProperties(properties map[string]*structpb.Value) *ResourceProperty

func (*ResourcePropertyMapper) New

func (*ResourcePropertyMapper) ResourceIdentity

func (m *ResourcePropertyMapper) ResourceIdentity() abs.ResourceIdentity

func (*ResourcePropertyMapper) ToProperties

func (m *ResourcePropertyMapper) ToProperties(resourceProperty *ResourceProperty) map[string]*structpb.Value

type ResourceReference

type ResourceReference struct {
	Resource      *Resource `json:"resource,omitempty"`
	Cascade       *bool     `json:"cascade,omitempty"`
	BackReference *string   `json:"backReference,omitempty"`
}

func (*ResourceReference) GetBackReference

func (s *ResourceReference) GetBackReference() *string

func (*ResourceReference) GetCascade

func (s *ResourceReference) GetCascade() *bool

func (*ResourceReference) GetResource

func (s *ResourceReference) GetResource() *Resource

type ResourceReferenceMapper

type ResourceReferenceMapper struct {
}

func NewResourceReferenceMapper

func NewResourceReferenceMapper() *ResourceReferenceMapper

func (*ResourceReferenceMapper) FromProperties

func (m *ResourceReferenceMapper) FromProperties(properties map[string]*structpb.Value) *ResourceReference

func (*ResourceReferenceMapper) New

func (*ResourceReferenceMapper) ResourceIdentity

func (m *ResourceReferenceMapper) ResourceIdentity() abs.ResourceIdentity

func (*ResourceReferenceMapper) ToProperties

func (m *ResourceReferenceMapper) ToProperties(resourceReference *ResourceReference) map[string]*structpb.Value

type ResourceSubType

type ResourceSubType struct {
	Name        string             `json:"name,omitempty"`
	Title       *string            `json:"title,omitempty"`
	Description *string            `json:"description,omitempty"`
	Properties  []ResourceProperty `json:"properties,omitempty"`
}

func (*ResourceSubType) GetDescription

func (s *ResourceSubType) GetDescription() *string

func (*ResourceSubType) GetName

func (s *ResourceSubType) GetName() string

func (*ResourceSubType) GetProperties

func (s *ResourceSubType) GetProperties() []ResourceProperty

func (*ResourceSubType) GetTitle

func (s *ResourceSubType) GetTitle() *string

type ResourceSubTypeMapper

type ResourceSubTypeMapper struct {
}

func NewResourceSubTypeMapper

func NewResourceSubTypeMapper() *ResourceSubTypeMapper

func (*ResourceSubTypeMapper) FromProperties

func (m *ResourceSubTypeMapper) FromProperties(properties map[string]*structpb.Value) *ResourceSubType

func (*ResourceSubTypeMapper) New

func (*ResourceSubTypeMapper) ResourceIdentity

func (m *ResourceSubTypeMapper) ResourceIdentity() abs.ResourceIdentity

func (*ResourceSubTypeMapper) ToProperties

func (m *ResourceSubTypeMapper) ToProperties(resourceSubType *ResourceSubType) map[string]*structpb.Value

type ResourceType

type ResourceType string
const (
	ResourceType_BOOL      ResourceType = "BOOL"
	ResourceType_STRING    ResourceType = "STRING"
	ResourceType_FLOAT32   ResourceType = "FLOAT32"
	ResourceType_FLOAT64   ResourceType = "FLOAT64"
	ResourceType_INT32     ResourceType = "INT32"
	ResourceType_INT64     ResourceType = "INT64"
	ResourceType_BYTES     ResourceType = "BYTES"
	ResourceType_UUID      ResourceType = "UUID"
	ResourceType_DATE      ResourceType = "DATE"
	ResourceType_TIME      ResourceType = "TIME"
	ResourceType_TIMESTAMP ResourceType = "TIMESTAMP"
	ResourceType_OBJECT    ResourceType = "OBJECT"
	ResourceType_MAP       ResourceType = "MAP"
	ResourceType_LIST      ResourceType = "LIST"
	ResourceType_REFERENCE ResourceType = "REFERENCE"
	ResourceType_ENUM      ResourceType = "ENUM"
	ResourceType_STRUCT    ResourceType = "STRUCT"
)

type Role

type Role struct {
	Id          *uuid.UUID                 `json:"id,omitempty"`
	Version     int32                      `json:"version,omitempty"`
	CreatedBy   *string                    `json:"createdBy,omitempty"`
	UpdatedBy   *string                    `json:"updatedBy,omitempty"`
	CreatedOn   *time.Time                 `json:"createdOn,omitempty"`
	UpdatedOn   *time.Time                 `json:"updatedOn,omitempty"`
	Name        string                     `json:"name,omitempty"`
	Permissions []*Permission              `json:"permissions,omitempty"`
	Details     *unstructured.Unstructured `json:"details,omitempty"`
}

func (*Role) GetCreatedBy

func (s *Role) GetCreatedBy() *string

func (*Role) GetCreatedOn

func (s *Role) GetCreatedOn() *time.Time

func (*Role) GetDetails

func (s *Role) GetDetails() *unstructured.Unstructured

func (*Role) GetId

func (s *Role) GetId() *uuid.UUID

func (*Role) GetName

func (s *Role) GetName() string

func (*Role) GetPermissions added in v1.1.44

func (s *Role) GetPermissions() []*Permission

func (*Role) GetUpdatedBy

func (s *Role) GetUpdatedBy() *string

func (*Role) GetUpdatedOn

func (s *Role) GetUpdatedOn() *time.Time

func (*Role) GetVersion

func (s *Role) GetVersion() int32

type RoleMapper

type RoleMapper struct {
}

func NewRoleMapper

func NewRoleMapper() *RoleMapper

func (*RoleMapper) FromProperties

func (m *RoleMapper) FromProperties(properties map[string]*structpb.Value) *Role

func (*RoleMapper) FromRecord

func (m *RoleMapper) FromRecord(record *model.Record) *Role

func (*RoleMapper) New

func (m *RoleMapper) New() *Role

func (*RoleMapper) ResourceIdentity

func (m *RoleMapper) ResourceIdentity() abs.ResourceIdentity

func (*RoleMapper) ToProperties

func (m *RoleMapper) ToProperties(role *Role) map[string]*structpb.Value

func (*RoleMapper) ToRecord

func (m *RoleMapper) ToRecord(role *Role) *model.Record

type User

type User struct {
	Id          *uuid.UUID                 `json:"id,omitempty"`
	Version     int32                      `json:"version,omitempty"`
	CreatedBy   *string                    `json:"createdBy,omitempty"`
	UpdatedBy   *string                    `json:"updatedBy,omitempty"`
	CreatedOn   *time.Time                 `json:"createdOn,omitempty"`
	UpdatedOn   *time.Time                 `json:"updatedOn,omitempty"`
	Username    string                     `json:"username,omitempty"`
	Password    *string                    `json:"password,omitempty"`
	Roles       []*Role                    `json:"roles,omitempty"`
	Permissions []*Permission              `json:"permissions,omitempty"`
	Details     *unstructured.Unstructured `json:"details,omitempty"`
}

func (*User) GetCreatedBy

func (s *User) GetCreatedBy() *string

func (*User) GetCreatedOn

func (s *User) GetCreatedOn() *time.Time

func (*User) GetDetails

func (s *User) GetDetails() *unstructured.Unstructured

func (*User) GetId

func (s *User) GetId() *uuid.UUID

func (*User) GetPassword

func (s *User) GetPassword() *string

func (*User) GetPermissions added in v1.1.44

func (s *User) GetPermissions() []*Permission

func (*User) GetRoles

func (s *User) GetRoles() []*Role

func (*User) GetUpdatedBy

func (s *User) GetUpdatedBy() *string

func (*User) GetUpdatedOn

func (s *User) GetUpdatedOn() *time.Time

func (*User) GetUsername

func (s *User) GetUsername() string

func (*User) GetVersion

func (s *User) GetVersion() int32

type UserMapper

type UserMapper struct {
}

func NewUserMapper

func NewUserMapper() *UserMapper

func (*UserMapper) FromProperties

func (m *UserMapper) FromProperties(properties map[string]*structpb.Value) *User

func (*UserMapper) FromRecord

func (m *UserMapper) FromRecord(record *model.Record) *User

func (*UserMapper) New

func (m *UserMapper) New() *User

func (*UserMapper) ResourceIdentity

func (m *UserMapper) ResourceIdentity() abs.ResourceIdentity

func (*UserMapper) ToProperties

func (m *UserMapper) ToProperties(user *User) map[string]*structpb.Value

func (*UserMapper) ToRecord

func (m *UserMapper) ToRecord(user *User) *model.Record

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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