memory

package
v0.5.6 Latest Latest
Warning

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

Go to latest
Published: Oct 13, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type InMemoryOrganizationRepository added in v0.5.0

type InMemoryOrganizationRepository struct {
	// contains filtered or unexported fields
}

func NewInMemoryOrganizationRepository added in v0.5.0

func NewInMemoryOrganizationRepository() *InMemoryOrganizationRepository

func (*InMemoryOrganizationRepository) AddMember added in v0.5.0

func (r *InMemoryOrganizationRepository) AddMember(ctx context.Context, organizationID, userID uuid.UUID, role string) error

func (*InMemoryOrganizationRepository) AddTeam added in v0.5.0

func (r *InMemoryOrganizationRepository) AddTeam(ctx context.Context, organizationID, teamID uuid.UUID) error

func (*InMemoryOrganizationRepository) Create added in v0.5.0

func (*InMemoryOrganizationRepository) Delete added in v0.5.0

func (*InMemoryOrganizationRepository) FindAll added in v0.5.0

func (*InMemoryOrganizationRepository) FindByID added in v0.5.0

func (*InMemoryOrganizationRepository) FindMember added in v0.5.0

func (r *InMemoryOrganizationRepository) FindMember(ctx context.Context, organizationID, userID uuid.UUID) (*entities.OrganizationMember, error)

func (*InMemoryOrganizationRepository) FindMemberMemberships added in v0.5.0

func (r *InMemoryOrganizationRepository) FindMemberMemberships(ctx context.Context, userID uuid.UUID) ([]*entities.OrganizationMember, error)

func (*InMemoryOrganizationRepository) FindMembers added in v0.5.0

func (r *InMemoryOrganizationRepository) FindMembers(ctx context.Context, organizationID uuid.UUID) ([]*entities.OrganizationMember, error)

func (*InMemoryOrganizationRepository) RemoveMember added in v0.5.0

func (r *InMemoryOrganizationRepository) RemoveMember(ctx context.Context, organizationID, userID uuid.UUID) error

func (*InMemoryOrganizationRepository) RemoveTeam added in v0.5.0

func (r *InMemoryOrganizationRepository) RemoveTeam(ctx context.Context, organizationID, teamID uuid.UUID) error

func (*InMemoryOrganizationRepository) Update added in v0.5.0

func (*InMemoryOrganizationRepository) UpdateMemberRole added in v0.5.0

func (r *InMemoryOrganizationRepository) UpdateMemberRole(ctx context.Context, organizationID, userID uuid.UUID, role string) error

type InMemoryTaskRepository

type InMemoryTaskRepository struct {
	// contains filtered or unexported fields
}

InMemoryTaskRepository is an in-memory task repository.

func NewInMemoryTaskRepository

func NewInMemoryTaskRepository() *InMemoryTaskRepository

NewInMemoryTaskRepository creates a new instance of InMemoryTaskRepository.

func (*InMemoryTaskRepository) Create

func (r *InMemoryTaskRepository) Create(ctx context.Context, task *entities.Task) error

Create adds a new task to the repository.

func (*InMemoryTaskRepository) Delete

func (r *InMemoryTaskRepository) Delete(ctx context.Context, id uuid.UUID) error

Delete removes a task from the repository.

func (*InMemoryTaskRepository) FindAll

FindAll returns all tasks in the repository.

func (*InMemoryTaskRepository) FindByID

FindByID returns the task with the specified ID.

func (*InMemoryTaskRepository) Update

func (r *InMemoryTaskRepository) Update(ctx context.Context, task *entities.Task) error

Update updates an existing task in the repository.

type InMemoryTaskRunRepository

type InMemoryTaskRunRepository struct {
	// contains filtered or unexported fields
}

InMemoryTaskRunRepository is an in-memory task run repository.

func NewInMemoryTaskRunRepository

func NewInMemoryTaskRunRepository() *InMemoryTaskRunRepository

NewInMemoryTaskRunRepository creates a new instance of InMemoryTaskRunRepository.

func (*InMemoryTaskRunRepository) Create

Create adds a new task run to the repository.

func (*InMemoryTaskRunRepository) Delete

Delete removes a task run from the repository.

func (*InMemoryTaskRunRepository) FindAll

FindAll returns all task runs in the repository.

func (*InMemoryTaskRunRepository) FindByID

FindByID returns the task run with the specified ID.

func (*InMemoryTaskRunRepository) FindByTaskID added in v0.2.0

func (r *InMemoryTaskRunRepository) FindByTaskID(ctx context.Context, taskID uuid.UUID) ([]*entities.TaskRun, error)

FindByTaskID returns all task runs for a task.

func (*InMemoryTaskRunRepository) Update

Update updates an existing task run in the repository.

type InMemoryTeamRepository

type InMemoryTeamRepository struct {
	// contains filtered or unexported fields
}

InMemoryTeamRepository is an in-memory repository that manages teams.

func NewInMemoryTeamRepository

func NewInMemoryTeamRepository() *InMemoryTeamRepository

NewInMemoryTeamRepository creates a new in-memory team repository.

func (*InMemoryTeamRepository) AddMember

func (r *InMemoryTeamRepository) AddMember(ctx context.Context, teamID, userID uuid.UUID, role string) error

AddMember adds a member to a team.

func (*InMemoryTeamRepository) Create

func (r *InMemoryTeamRepository) Create(ctx context.Context, team *entities.Team) error

Create adds a new team to the repository.

func (*InMemoryTeamRepository) Delete

func (r *InMemoryTeamRepository) Delete(ctx context.Context, id uuid.UUID) error

Delete removes a team from the repository.

func (*InMemoryTeamRepository) FindAll

func (r *InMemoryTeamRepository) FindAll(ctx context.Context) ([]*entities.Team, error)

FindAll returns all teams in the repository.

func (*InMemoryTeamRepository) FindByID

func (r *InMemoryTeamRepository) FindByID(ctx context.Context, id uuid.UUID) (*entities.Team, error)

FindByID returns the team with the specified ID.

func (*InMemoryTeamRepository) FindMember added in v0.5.0

func (r *InMemoryTeamRepository) FindMember(ctx context.Context, teamID, userID uuid.UUID) (*entities.TeamMember, error)

FindMember returns a member of a team.

func (*InMemoryTeamRepository) FindMemberMemberships added in v0.5.0

func (r *InMemoryTeamRepository) FindMemberMemberships(ctx context.Context, userID uuid.UUID) ([]*entities.TeamMember, error)

FindMemberMemberships returns all memberships of a member.

func (*InMemoryTeamRepository) FindMembers added in v0.5.0

func (r *InMemoryTeamRepository) FindMembers(ctx context.Context, teamID uuid.UUID) ([]*entities.TeamMember, error)

FindMembers returns all members of a team.

func (*InMemoryTeamRepository) RemoveMember

func (r *InMemoryTeamRepository) RemoveMember(ctx context.Context, teamID, userID uuid.UUID) error

RemoveMember removes a member from a team.

func (*InMemoryTeamRepository) Update

func (r *InMemoryTeamRepository) Update(ctx context.Context, team *entities.Team) error

Update updates an existing team in the repository.

func (*InMemoryTeamRepository) UpdateMemberRole

func (r *InMemoryTeamRepository) UpdateMemberRole(ctx context.Context, teamID, userID uuid.UUID, role string) error

UpdateMemberRole updates the role of a member in a team.

type InMemoryUserRepository

type InMemoryUserRepository struct {
	// contains filtered or unexported fields
}

InMemoryUserRepository is an in-memory user repository.

func NewInMemoryUserRepository

func NewInMemoryUserRepository() *InMemoryUserRepository

NewInMemoryUserRepository creates a new in-memory user repository.

func (*InMemoryUserRepository) Create

func (r *InMemoryUserRepository) Create(ctx context.Context, user *entities.User) error

Create adds a new user to the repository.

func (*InMemoryUserRepository) Delete

func (r *InMemoryUserRepository) Delete(ctx context.Context, id uuid.UUID) error

Delete removes a user from the repository.

func (*InMemoryUserRepository) FindAll

func (r *InMemoryUserRepository) FindAll(ctx context.Context) ([]*entities.User, error)

FindAll returns all users in the repository.

func (*InMemoryUserRepository) FindByEmail added in v0.5.0

func (r *InMemoryUserRepository) FindByEmail(ctx context.Context, email string) (*entities.User, error)

FindByEmail returns the user with the specified email.

func (*InMemoryUserRepository) FindByID

func (r *InMemoryUserRepository) FindByID(ctx context.Context, id uuid.UUID) (*entities.User, error)

FindByID returns the user with the specified ID.

func (*InMemoryUserRepository) Update

func (r *InMemoryUserRepository) Update(ctx context.Context, user *entities.User) error

Update updates an existing user in the repository.

type TriggerRepository

type TriggerRepository struct {
	// contains filtered or unexported fields
}

TriggerRepository is a repository that manages triggers in memory.

func NewInMemoryTriggerRepository

func NewInMemoryTriggerRepository() *TriggerRepository

NewInMemoryTriggerRepository creates a new in-memory trigger repository.

func (*TriggerRepository) Create

func (r *TriggerRepository) Create(ctx context.Context, trigger *entities.Trigger) error

Create creates a new trigger.

func (*TriggerRepository) Delete

func (r *TriggerRepository) Delete(ctx context.Context, id uuid.UUID) error

Delete deletes a trigger by ID.

func (*TriggerRepository) FindAll

func (r *TriggerRepository) FindAll(ctx context.Context) ([]*entities.Trigger, error)

FindAll returns all triggers.

func (*TriggerRepository) FindByID

func (r *TriggerRepository) FindByID(ctx context.Context, id uuid.UUID) (*entities.Trigger, error)

FindByID returns a trigger by ID.

func (*TriggerRepository) Update

func (r *TriggerRepository) Update(ctx context.Context, trigger *entities.Trigger) error

Update updates a trigger.

Jump to

Keyboard shortcuts

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