Package akka.actor.typed.internal
Class LogMessagesInterceptor<T>
- java.lang.Object
-
- akka.actor.typed.BehaviorInterceptor<T,T>
-
- akka.actor.typed.internal.LogMessagesInterceptor<T>
-
- All Implemented Interfaces:
java.io.Serializable
,scala.Equals
,scala.Product
,scala.Serializable
public final class LogMessagesInterceptor<T> extends BehaviorInterceptor<T,T> implements scala.Product, scala.Serializable
Log all messages for this decorated ReceiveTarget[T] to logger before receiving it ourselves.INTERNAL API
- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class akka.actor.typed.BehaviorInterceptor
BehaviorInterceptor.PreStartTarget<T>, BehaviorInterceptor.ReceiveTarget<T>, BehaviorInterceptor.SignalTarget<T>
-
-
Constructor Summary
Constructors Constructor Description LogMessagesInterceptor(LogOptions opts)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static <T> LogMessagesInterceptor<T>
apply(LogOptions opts)
Behavior<T>
aroundReceive(TypedActorContext<T> ctx, T msg, BehaviorInterceptor.ReceiveTarget<T> target)
Intercept a message sent to the running actor.Behavior<T>
aroundSignal(TypedActorContext<T> ctx, Signal signal, BehaviorInterceptor.SignalTarget<T> target)
Intercept a signal sent to the running actor.boolean
canEqual(java.lang.Object x$1)
<T> LogMessagesInterceptor<T>
copy(LogOptions opts)
<T> LogOptions
copy$default$1()
boolean
equals(java.lang.Object x$1)
int
hashCode()
boolean
isSame(BehaviorInterceptor<java.lang.Object,java.lang.Object> other)
LogOptions
opts()
int
productArity()
java.lang.Object
productElement(int x$1)
scala.collection.Iterator<java.lang.Object>
productIterator()
java.lang.String
productPrefix()
java.lang.String
toString()
static <T> scala.Option<LogOptions>
unapply(LogMessagesInterceptor<T> x$0)
-
Methods inherited from class akka.actor.typed.BehaviorInterceptor
aroundStart, interceptMessageType
-
-
-
-
Constructor Detail
-
LogMessagesInterceptor
public LogMessagesInterceptor(LogOptions opts)
-
-
Method Detail
-
apply
public static <T> LogMessagesInterceptor<T> apply(LogOptions opts)
-
unapply
public static <T> scala.Option<LogOptions> unapply(LogMessagesInterceptor<T> x$0)
-
opts
public LogOptions opts()
-
aroundReceive
public Behavior<T> aroundReceive(TypedActorContext<T> ctx, T msg, BehaviorInterceptor.ReceiveTarget<T> target)
Description copied from class:BehaviorInterceptor
Intercept a message sent to the running actor. Pass the message on to the next behavior in the stack by passing it totarget.apply
, returnBehaviors.same
without invokingtarget
to filter out the message.- Specified by:
aroundReceive
in classBehaviorInterceptor<T,T>
- Parameters:
ctx
- (undocumented)msg
- (undocumented)target
- (undocumented)- Returns:
- The behavior for next message or signal
-
aroundSignal
public Behavior<T> aroundSignal(TypedActorContext<T> ctx, Signal signal, BehaviorInterceptor.SignalTarget<T> target)
Description copied from class:BehaviorInterceptor
Intercept a signal sent to the running actor. Pass the signal on to the next behavior in the stack by passing it totarget.apply
.- Specified by:
aroundSignal
in classBehaviorInterceptor<T,T>
- Parameters:
ctx
- (undocumented)signal
- (undocumented)target
- (undocumented)- Returns:
- The behavior for next message or signal
-
isSame
public boolean isSame(BehaviorInterceptor<java.lang.Object,java.lang.Object> other)
- Overrides:
isSame
in classBehaviorInterceptor<T,T>
- Parameters:
other
- (undocumented)- Returns:
true
if this behavior logically the same as another behavior interceptor and can therefore be eliminated (to avoid building infinitely growing stacks of behaviors)? Default implementation is based on instance equality. Override to provide use case specific logic.
-
copy
public <T> LogMessagesInterceptor<T> copy(LogOptions opts)
-
copy$default$1
public <T> LogOptions copy$default$1()
-
productPrefix
public java.lang.String productPrefix()
- Specified by:
productPrefix
in interfacescala.Product
-
productArity
public int productArity()
- Specified by:
productArity
in interfacescala.Product
-
productElement
public java.lang.Object productElement(int x$1)
- Specified by:
productElement
in interfacescala.Product
-
productIterator
public scala.collection.Iterator<java.lang.Object> productIterator()
- Specified by:
productIterator
in interfacescala.Product
-
canEqual
public boolean canEqual(java.lang.Object x$1)
- Specified by:
canEqual
in interfacescala.Equals
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
equals
public boolean equals(java.lang.Object x$1)
- Specified by:
equals
in interfacescala.Equals
- Overrides:
equals
in classjava.lang.Object
-
-