domain

package
v0.9.1 Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2020 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ControllerFunc

type ControllerFunc func(controller *Domain) error

ControllerFunc is the function signature for domain validation functions

type Domain

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

Domain is the domain controller

func NewController

func NewController(ctx sdk.Context, k keeper.Keeper, domain string) *Domain

NewController is the constructor for Domain everything is processed sequentially, a wrong order of the sequence is forbidden, example: asserting domain expiration on a non existing domain causes a panic as it violates the condition scope of action.

func (*Domain) Admin added in v0.9.1

func (c *Domain) Admin(addr sdk.AccAddress) *Domain

func (*Domain) DeletableBy added in v0.9.1

func (c *Domain) DeletableBy(addr sdk.AccAddress) *Domain

Deletable checks if the domain can be deleted by the provided address

func (*Domain) Domain

func (c *Domain) Domain() types.Domain

Domain returns a copy the domain, panics if the operation is done without doing validity checks on domain existence as it is not an allowed op

func (*Domain) MustExist added in v0.9.1

func (c *Domain) MustExist() *Domain

MustExist checks if the provided domain exists

func (*Domain) MustNotExist added in v0.9.1

func (c *Domain) MustNotExist() *Domain

MustNotExist checks if the provided domain does not exist

func (*Domain) NotExpired added in v0.9.1

func (c *Domain) NotExpired() *Domain

func (*Domain) Renewable added in v0.9.1

func (c *Domain) Renewable() *Domain

Renewable checks if the domain is allowed to be renewed

func (*Domain) Transferable added in v0.9.1

func (c *Domain) Transferable(flag types.TransferFlag) *Domain

func (*Domain) Type added in v0.9.1

func (c *Domain) Type(Type types.DomainType) *Domain

Superuser makes sure the domain superuser is set to the provided condition

func (*Domain) ValidName added in v0.9.1

func (c *Domain) ValidName() *Domain

ValidAccountName checks if the name of the domain is valid

func (*Domain) Validate

func (c *Domain) Validate() error

Validate validates a domain based on the provided checks

func (*Domain) WithConfiguration

func (c *Domain) WithConfiguration(cfg configuration.Config) *Domain

WithConfiguration allows to specify a cached config

func (*Domain) WithDomain

func (c *Domain) WithDomain(dom types.Domain) *Domain

WithDomain creates a domain controller with a cached domain

Jump to

Keyboard shortcuts

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