controllers

package
v0.0.10 Latest Latest
Warning

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

Go to latest
Published: Jun 7, 2022 License: AGPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Controllers = map[string]api.APIControllerMaker{
	"inMemory": MakeInMemoryController,
}

Functions

func MakeInMemoryController

func MakeInMemoryController(config map[string]interface{}, controller kodex.Controller, definitions *api.Definitions) (api.Controller, error)

func MakeInMemoryObjectRole

func MakeInMemoryObjectRole(id, organizationID, objectID []byte, objectType string, controller *InMemoryController) api.ObjectRole

Types

type InMemoryController

type InMemoryController struct {
	api.BaseController

	*kodexControllers.InMemoryController
	// contains filtered or unexported fields
}

func (*InMemoryController) DeleteObjectRole

func (m *InMemoryController) DeleteObjectRole(objectRole *InMemoryObjectRole) error

func (*InMemoryController) KodexController

func (m *InMemoryController) KodexController() kodex.Controller

func (*InMemoryController) MakeObjectRole

func (m *InMemoryController) MakeObjectRole(object kodex.Model, organization api.Organization) api.ObjectRole

func (*InMemoryController) MakeOrganization

func (c *InMemoryController) MakeOrganization() api.Organization

func (*InMemoryController) ObjectRole

func (m *InMemoryController) ObjectRole(id []byte) (api.ObjectRole, error)

func (*InMemoryController) ObjectRolesForOrganizationRoles

func (m *InMemoryController) ObjectRolesForOrganizationRoles(objectType string, organizationRoles []string, organizationID []byte) ([]api.ObjectRole, error)

func (*InMemoryController) Organization

func (c *InMemoryController) Organization(source string, sourceID []byte) (api.Organization, error)

func (*InMemoryController) Organizations

func (c *InMemoryController) Organizations(filters map[string]interface{}) ([]api.Organization, error)

func (*InMemoryController) RolesForObject

func (m *InMemoryController) RolesForObject(object kodex.Model) ([]api.ObjectRole, error)

func (*InMemoryController) SaveObjectRole

func (m *InMemoryController) SaveObjectRole(objectRole *InMemoryObjectRole) error

func (*InMemoryController) SaveOrganization

func (c *InMemoryController) SaveOrganization(organization *InMemoryOrganization) error

type InMemoryObjectRole

type InMemoryObjectRole struct {
	api.BaseObjectRole
	// contains filtered or unexported fields
}

func (*InMemoryObjectRole) CreatedAt

func (c *InMemoryObjectRole) CreatedAt() time.Time

func (*InMemoryObjectRole) Delete

func (c *InMemoryObjectRole) Delete() error

func (*InMemoryObjectRole) DeletedAt

func (c *InMemoryObjectRole) DeletedAt() *time.Time

func (*InMemoryObjectRole) ID

func (c *InMemoryObjectRole) ID() []byte

func (*InMemoryObjectRole) ObjectID

func (c *InMemoryObjectRole) ObjectID() []byte

func (*InMemoryObjectRole) ObjectRole

func (c *InMemoryObjectRole) ObjectRole() string

func (*InMemoryObjectRole) ObjectType

func (c *InMemoryObjectRole) ObjectType() string

func (*InMemoryObjectRole) OrganizationID

func (c *InMemoryObjectRole) OrganizationID() []byte

func (*InMemoryObjectRole) OrganizationRole

func (c *InMemoryObjectRole) OrganizationRole() string

func (*InMemoryObjectRole) Refresh

func (c *InMemoryObjectRole) Refresh() error

func (*InMemoryObjectRole) Save

func (c *InMemoryObjectRole) Save() error

func (*InMemoryObjectRole) SetObjectID

func (c *InMemoryObjectRole) SetObjectID(id []byte) error

func (*InMemoryObjectRole) SetObjectRole

func (c *InMemoryObjectRole) SetObjectRole(role string) error

func (*InMemoryObjectRole) SetOrganizationRole

func (c *InMemoryObjectRole) SetOrganizationRole(role string) error

func (*InMemoryObjectRole) UpdatedAt

func (c *InMemoryObjectRole) UpdatedAt() time.Time

type InMemoryOrganization

type InMemoryOrganization struct {
	api.BaseOrganization
	// contains filtered or unexported fields
}

func MakeInMemoryOrganization

func MakeInMemoryOrganization(id []byte,
	controller api.Controller) *InMemoryOrganization

func (*InMemoryOrganization) CreatedAt

func (i *InMemoryOrganization) CreatedAt() time.Time

func (*InMemoryOrganization) Data

func (i *InMemoryOrganization) Data() interface{}

func (*InMemoryOrganization) Delete

func (i *InMemoryOrganization) Delete() error

func (*InMemoryOrganization) DeletedAt

func (i *InMemoryOrganization) DeletedAt() *time.Time

func (*InMemoryOrganization) Description

func (i *InMemoryOrganization) Description() string

func (*InMemoryOrganization) ID

func (i *InMemoryOrganization) ID() []byte

func (*InMemoryOrganization) Name

func (i *InMemoryOrganization) Name() string

func (*InMemoryOrganization) Refresh

func (i *InMemoryOrganization) Refresh() error

func (*InMemoryOrganization) Save

func (i *InMemoryOrganization) Save() error

func (*InMemoryOrganization) SetData

func (i *InMemoryOrganization) SetData(data interface{}) error

func (*InMemoryOrganization) SetDescription

func (i *InMemoryOrganization) SetDescription(description string) error

func (*InMemoryOrganization) SetName

func (i *InMemoryOrganization) SetName(name string) error

func (*InMemoryOrganization) SetSource

func (i *InMemoryOrganization) SetSource(source string) error

func (*InMemoryOrganization) SetSourceID

func (i *InMemoryOrganization) SetSourceID(sourceID []byte) error

func (*InMemoryOrganization) Source

func (i *InMemoryOrganization) Source() string

func (*InMemoryOrganization) SourceID

func (i *InMemoryOrganization) SourceID() []byte

func (*InMemoryOrganization) UpdatedAt

func (i *InMemoryOrganization) UpdatedAt() time.Time

Jump to

Keyboard shortcuts

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