Package akka.actor
Class Props$
- java.lang.Object
-
- akka.actor.Props$
-
- All Implemented Interfaces:
AbstractProps
,java.io.Serializable
,scala.Serializable
public class Props$ extends java.lang.Object implements AbstractProps, scala.Serializable
The defaultCreator, simply throws an UnsupportedOperationException when applied, which is used when creating a Props- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description Props$()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Props
apply(Deploy deploy, java.lang.Class<?> clazz, scala.collection.immutable.Seq<java.lang.Object> args)
Props is a configuration object using in creating anActor
; it is immutable, so it is thread-safe and fully shareable.Props
apply(java.lang.Class<?> clazz, scala.collection.Seq<java.lang.Object> args)
Scala API: create a Props given a class and its constructor arguments.<T extends Actor>
Propsapply(scala.Function0<T> creator, scala.reflect.ClassTag<T> evidence$2)
Scala API: Returns a Props that has default values except for "creator" which will be a function that creates an instance using the supplied thunk.<T extends Actor>
Propsapply(scala.reflect.ClassTag<T> evidence$1)
scala.Function0<Actor>
defaultCreator()
Deploy
defaultDeploy()
The default Deploy instance which is used when creating a PropsRouterConfig
defaultRoutedProps()
The defaultRoutedProps is NoRouter which is used when creating a PropsProps
empty()
A Props instance whose creator will create an actor that doesn't respond to any messagescala.Option<scala.Tuple3<Deploy,java.lang.Class<?>,scala.collection.immutable.Seq<java.lang.Object>>>
unapply(Props x$0)
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface akka.actor.AbstractProps
checkCreatorClosingOver, create, create, create, create, validate
-
-
-
-
Field Detail
-
MODULE$
public static final Props$ MODULE$
Static reference to the singleton instance of this Scala object.
-
-
Method Detail
-
defaultCreator
public final scala.Function0<Actor> defaultCreator()
-
defaultRoutedProps
public final RouterConfig defaultRoutedProps()
The defaultRoutedProps is NoRouter which is used when creating a Props- Returns:
- (undocumented)
-
defaultDeploy
public final Deploy defaultDeploy()
The default Deploy instance which is used when creating a Props- Returns:
- (undocumented)
-
empty
public final Props empty()
A Props instance whose creator will create an actor that doesn't respond to any message- Returns:
- (undocumented)
-
apply
public <T extends Actor> Props apply(scala.Function0<T> creator, scala.reflect.ClassTag<T> evidence$2)
Scala API: Returns a Props that has default values except for "creator" which will be a function that creates an instance using the supplied thunk.CAVEAT: Required mailbox type cannot be detected when using anonymous mixin composition when creating the instance. For example, the following will not detect the need for
DequeBasedMessageQueueSemantics
as defined inStash
:
Instead you must create a named class that mixin the trait, e.g.'Props(new Actor with Stash { ... })
class MyActor extends Actor with Stash
.- Parameters:
creator
- (undocumented)evidence$2
- (undocumented)- Returns:
- (undocumented)
-
apply
public Props apply(java.lang.Class<?> clazz, scala.collection.Seq<java.lang.Object> args)
Scala API: create a Props given a class and its constructor arguments.- Parameters:
clazz
- (undocumented)args
- (undocumented)- Returns:
- (undocumented)
-
apply
public Props apply(Deploy deploy, java.lang.Class<?> clazz, scala.collection.immutable.Seq<java.lang.Object> args)
Props is a configuration object using in creating anActor
; it is immutable, so it is thread-safe and fully shareable.Examples on Scala API:
val props = Props.empty val props = Props[MyActor] val props = Props(classOf[MyActor], arg1, arg2) val otherProps = props.withDispatcher("dispatcher-id") val otherProps = props.withDeploy(<deployment info>)
Examples on Java API:
final Props props = Props.empty(); final Props props = Props.create(MyActor.class, arg1, arg2); final Props otherProps = props.withDispatcher("dispatcher-id"); final Props otherProps = props.withDeploy(<deployment info>);
- Parameters:
deploy
- (undocumented)clazz
- (undocumented)args
- (undocumented)- Returns:
- (undocumented)
-
-