Documentation ¶
Index ¶
- Constants
- type Actor
- type ActorCell
- func (cell *ActorCell) ActorOf(props Properties) ActorRef
- func (cell *ActorCell) Become(behavior Receive)
- func (cell *ActorCell) BecomeStacked(behavior Receive)
- func (cell *ActorCell) Children() []ActorRef
- func (cell *ActorCell) Parent() ActorRef
- func (cell *ActorCell) Self() ActorRef
- func (cell *ActorCell) UnbecomeStacked()
- func (cell *ActorCell) Unwatch(who ActorRef)
- func (cell *ActorCell) Watch(who ActorRef)
- type ActorProducer
- type ActorRef
- type BoundedMailbox
- func (mailbox *BoundedMailbox) PostSystemMessage(message SystemMessage)
- func (mailbox *BoundedMailbox) PostUserMessage(message interface{})
- func (mailbox *BoundedMailbox) RegisterHandlers(userInvoke func(interface{}), systemInvoke func(SystemMessage))
- func (mailbox *BoundedMailbox) Resume()
- func (mailbox *BoundedMailbox) Suspend()
- type Context
- type ContextValue
- type Decider
- type Directive
- type Failure
- type FutureActorRef
- func (ref *FutureActorRef) Result() interface{}
- func (ref *FutureActorRef) ResultChannel() <-chan interface{}
- func (ref *FutureActorRef) ResultOrTimeout(timeout time.Duration) (interface{}, error)
- func (ref *FutureActorRef) SendSystemMessage(message SystemMessage)
- func (ref *FutureActorRef) Stop()
- func (ref *FutureActorRef) Tell(message interface{})
- type LocalActorRef
- type Mailbox
- type MailboxProducer
- type OneForOneStrategy
- type OtherStopped
- type PoisonPill
- type Properties
- type PropsValue
- type Receive
- type Restart
- type Restarting
- type Resume
- type Started
- type Stop
- type Stopped
- type Stopping
- type SupervisionStrategy
- type SystemMessage
- type UnboundedMailbox
- func (mailbox *UnboundedMailbox) PostSystemMessage(message SystemMessage)
- func (mailbox *UnboundedMailbox) PostUserMessage(message interface{})
- func (mailbox *UnboundedMailbox) RegisterHandlers(userInvoke func(interface{}), systemInvoke func(SystemMessage))
- func (mailbox *UnboundedMailbox) Resume()
- func (mailbox *UnboundedMailbox) Suspend()
- type Unwatch
- type Watch
Constants ¶
View Source
const ( MailboxIdle = iota MailboxRunning = iota )
View Source
const ( MailboxHasNoMessages = iota MailboxHasMoreMessages = iota )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ActorCell ¶
type ActorCell struct {
// contains filtered or unexported fields
}
func NewActorCell ¶
func NewActorCell(props Properties, parent ActorRef) *ActorCell
func (*ActorCell) ActorOf ¶
func (cell *ActorCell) ActorOf(props Properties) ActorRef
func (*ActorCell) BecomeStacked ¶
func (*ActorCell) UnbecomeStacked ¶
func (cell *ActorCell) UnbecomeStacked()
type ActorProducer ¶
type ActorProducer func() Actor
type ActorRef ¶
type ActorRef interface { Tell(message interface{}) SendSystemMessage(message SystemMessage) Stop() }
func ActorOf ¶
func ActorOf(props Properties) ActorRef
type BoundedMailbox ¶
type BoundedMailbox struct {
// contains filtered or unexported fields
}
func (*BoundedMailbox) PostSystemMessage ¶
func (mailbox *BoundedMailbox) PostSystemMessage(message SystemMessage)
func (*BoundedMailbox) PostUserMessage ¶
func (mailbox *BoundedMailbox) PostUserMessage(message interface{})
func (*BoundedMailbox) RegisterHandlers ¶
func (mailbox *BoundedMailbox) RegisterHandlers(userInvoke func(interface{}), systemInvoke func(SystemMessage))
func (*BoundedMailbox) Resume ¶
func (mailbox *BoundedMailbox) Resume()
func (*BoundedMailbox) Suspend ¶
func (mailbox *BoundedMailbox) Suspend()
type Context ¶
type Context interface { Watch(ActorRef) Unwatch(ActorRef) Message() interface{} Become(Receive) BecomeStacked(Receive) UnbecomeStacked() Self() ActorRef Parent() ActorRef ActorOf(Properties) ActorRef Children() []ActorRef }
func NewContext ¶
type ContextValue ¶
type ContextValue struct { *ActorCell // contains filtered or unexported fields }
func (*ContextValue) Message ¶
func (context *ContextValue) Message() interface{}
type Failure ¶
type Failure struct { Who ActorRef Reason interface{} }
func (*Failure) SystemMessage ¶
func (*Failure) SystemMessage()
type FutureActorRef ¶
type FutureActorRef struct {
// contains filtered or unexported fields
}
func NewFutureActorRef ¶
func NewFutureActorRef() *FutureActorRef
func (*FutureActorRef) Result ¶
func (ref *FutureActorRef) Result() interface{}
func (*FutureActorRef) ResultChannel ¶
func (ref *FutureActorRef) ResultChannel() <-chan interface{}
func (*FutureActorRef) ResultOrTimeout ¶
func (ref *FutureActorRef) ResultOrTimeout(timeout time.Duration) (interface{}, error)
func (*FutureActorRef) SendSystemMessage ¶
func (ref *FutureActorRef) SendSystemMessage(message SystemMessage)
func (*FutureActorRef) Stop ¶
func (ref *FutureActorRef) Stop()
func (*FutureActorRef) Tell ¶
func (ref *FutureActorRef) Tell(message interface{})
type LocalActorRef ¶
type LocalActorRef struct {
// contains filtered or unexported fields
}
func NewLocalActorRef ¶
func NewLocalActorRef(mailbox Mailbox) *LocalActorRef
func (*LocalActorRef) Resume ¶
func (ref *LocalActorRef) Resume()
func (*LocalActorRef) SendSystemMessage ¶
func (ref *LocalActorRef) SendSystemMessage(message SystemMessage)
func (*LocalActorRef) Stop ¶
func (ref *LocalActorRef) Stop()
func (*LocalActorRef) Suspend ¶
func (ref *LocalActorRef) Suspend()
func (*LocalActorRef) Tell ¶
func (ref *LocalActorRef) Tell(message interface{})
type Mailbox ¶
type Mailbox interface { PostUserMessage(message interface{}) PostSystemMessage(message SystemMessage) Suspend() Resume() RegisterHandlers(userInvoke func(interface{}), systemInvoke func(SystemMessage)) }
func NewBoundedMailbox ¶
func NewUnboundedMailbox ¶
func NewUnboundedMailbox() Mailbox
type MailboxProducer ¶
type MailboxProducer func(func(interface{}), func(SystemMessage)) Mailbox
type OneForOneStrategy ¶
type OneForOneStrategy struct {
// contains filtered or unexported fields
}
func (*OneForOneStrategy) Handle ¶
func (strategy *OneForOneStrategy) Handle(child ActorRef, reason interface{}) Directive
type OtherStopped ¶
type OtherStopped struct {
Who ActorRef
}
func (*OtherStopped) SystemMessage ¶
func (*OtherStopped) SystemMessage()
type PoisonPill ¶
type PoisonPill struct{}
type Properties ¶
type Properties interface { ProduceActor() Actor Mailbox() Mailbox Supervisor() SupervisionStrategy }
type PropsValue ¶
type PropsValue struct {
// contains filtered or unexported fields
}
func Props ¶
func Props(actorProducer ActorProducer) PropsValue
func (PropsValue) Mailbox ¶
func (props PropsValue) Mailbox() Mailbox
func (PropsValue) ProduceActor ¶
func (props PropsValue) ProduceActor() Actor
func (PropsValue) Supervisor ¶
func (props PropsValue) Supervisor() SupervisionStrategy
func (PropsValue) WithMailbox ¶
func (props PropsValue) WithMailbox(mailbox Mailbox) PropsValue
func (PropsValue) WithSupervisor ¶
func (props PropsValue) WithSupervisor(supervisor SupervisionStrategy) PropsValue
type Restart ¶
type Restart struct{}
func (*Restart) SystemMessage ¶
func (*Restart) SystemMessage()
type SupervisionStrategy ¶
func DefaultSupervisionStrategy ¶
func DefaultSupervisionStrategy() SupervisionStrategy
func NewOneForOneStrategy ¶
func NewOneForOneStrategy(maxNrOfRetries int, withinTimeRangeMilliseconds int, decider Decider) SupervisionStrategy
type SystemMessage ¶
type SystemMessage interface {
SystemMessage()
}
type UnboundedMailbox ¶
type UnboundedMailbox struct {
// contains filtered or unexported fields
}
func (*UnboundedMailbox) PostSystemMessage ¶
func (mailbox *UnboundedMailbox) PostSystemMessage(message SystemMessage)
func (*UnboundedMailbox) PostUserMessage ¶
func (mailbox *UnboundedMailbox) PostUserMessage(message interface{})
func (*UnboundedMailbox) RegisterHandlers ¶
func (mailbox *UnboundedMailbox) RegisterHandlers(userInvoke func(interface{}), systemInvoke func(SystemMessage))
func (*UnboundedMailbox) Resume ¶
func (mailbox *UnboundedMailbox) Resume()
func (*UnboundedMailbox) Suspend ¶
func (mailbox *UnboundedMailbox) Suspend()
Source Files ¶
Click to show internal directories.
Click to hide internal directories.