Package akka.actor.typed.receptionist
Class ServiceKey<T>
- java.lang.Object
-
- akka.actor.typed.internal.receptionist.AbstractServiceKey
-
- akka.actor.typed.receptionist.ServiceKey<T>
-
- Direct Known Subclasses:
DefaultServiceKey
public abstract class ServiceKey<T> extends akka.actor.typed.internal.receptionist.AbstractServiceKey
A service key is an object that implements this trait for a given protocol T, meaning that it signifies that the type T is the entry point into the protocol spoken by that service (think of it as the set of first messages that a client could send).Not for user extension, see factories in companion object:
create(java.lang.Class<T>, java.lang.String)
andapply(java.lang.String, scala.reflect.ClassTag<T>)
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description class
ServiceKey.Listing$
Scala API: Provides a type safe pattern match for listings.class
ServiceKey.Registered$
Scala API: Provides a type safe pattern match for registration acks
-
Constructor Summary
Constructors Constructor Description ServiceKey()
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description static <T> ServiceKey<T>
apply(java.lang.String id, scala.reflect.ClassTag<T> classTag)
Scala API: Creates a service key.ServiceKey<T>
asServiceKey()
static <T> ServiceKey<T>
create(java.lang.Class<T> clazz, java.lang.String id)
Java API: Creates a service key.abstract java.lang.String
id()
ServiceKey.Listing$
Listing()
Accessor for nested Scala objectServiceKey.Registered$
Registered()
Accessor for nested Scala object
-
-
-
Method Detail
-
apply
public static <T> ServiceKey<T> apply(java.lang.String id, scala.reflect.ClassTag<T> classTag)
Scala API: Creates a service key. The given ID should uniquely define a service with a given protocol.
-
create
public static <T> ServiceKey<T> create(java.lang.Class<T> clazz, java.lang.String id)
Java API: Creates a service key. The given ID should uniquely define a service with a given protocol.
-
Listing
public ServiceKey.Listing$ Listing()
Accessor for nested Scala object- Returns:
- (undocumented)
-
Registered
public ServiceKey.Registered$ Registered()
Accessor for nested Scala object- Returns:
- (undocumented)
-
id
public abstract java.lang.String id()
-
asServiceKey
public ServiceKey<T> asServiceKey()
-
-