org.infinispan.interceptors
Class MarshalledValueInterceptor
java.lang.Object
org.infinispan.commands.AbstractVisitor
org.infinispan.interceptors.base.CommandInterceptor
org.infinispan.interceptors.MarshalledValueInterceptor
- All Implemented Interfaces:
- Visitor
public class MarshalledValueInterceptor
- extends CommandInterceptor
Interceptor that handles the wrapping and unwrapping of cached data using MarshalledValues. Known "excluded" types are not wrapped/unwrapped, which at this time
include String, Java primitives and their Object wrappers, as well as arrays of excluded types.
The MarshalledValue wrapper handles lazy deserialization from byte array
representations.
- Since:
- 4.0
- Author:
- Manik Surtani (manik@jboss.org), Mircea.Markus@jboss.com, Galder ZamarreƱo
- See Also:
MarshalledValue
|
Method Summary |
protected MarshalledValue |
createMarshalledValue(Object toWrap,
InvocationContext ctx)
|
protected void |
injectMarshaller(StreamingMarshaller marshaller)
|
Object |
visitEntrySetCommand(InvocationContext ctx,
EntrySetCommand command)
|
Object |
visitEvictCommand(InvocationContext ctx,
EvictCommand command)
|
Object |
visitGetKeyValueCommand(InvocationContext ctx,
GetKeyValueCommand command)
|
Object |
visitInvalidateCommand(InvocationContext ctx,
InvalidateCommand command)
|
Object |
visitKeySetCommand(InvocationContext ctx,
KeySetCommand command)
|
Object |
visitLockControlCommand(TxInvocationContext ctx,
LockControlCommand command)
|
Object |
visitPutKeyValueCommand(InvocationContext ctx,
PutKeyValueCommand command)
|
Object |
visitPutMapCommand(InvocationContext ctx,
PutMapCommand command)
|
Object |
visitRemoveCommand(InvocationContext ctx,
RemoveCommand command)
|
Object |
visitReplaceCommand(InvocationContext ctx,
ReplaceCommand command)
|
Object |
visitValuesCommand(InvocationContext ctx,
ValuesCommand command)
|
protected Map |
wrapMap(Map<Object,Object> m,
Set<MarshalledValue> marshalledValues,
InvocationContext ctx)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
MarshalledValueInterceptor
public MarshalledValueInterceptor()
injectMarshaller
protected void injectMarshaller(StreamingMarshaller marshaller)
visitLockControlCommand
public Object visitLockControlCommand(TxInvocationContext ctx,
LockControlCommand command)
throws Throwable
- Specified by:
visitLockControlCommand in interface Visitor- Overrides:
visitLockControlCommand in class AbstractVisitor
- Throws:
Throwable
visitPutMapCommand
public Object visitPutMapCommand(InvocationContext ctx,
PutMapCommand command)
throws Throwable
- Specified by:
visitPutMapCommand in interface Visitor- Overrides:
visitPutMapCommand in class AbstractVisitor
- Throws:
Throwable
visitPutKeyValueCommand
public Object visitPutKeyValueCommand(InvocationContext ctx,
PutKeyValueCommand command)
throws Throwable
- Specified by:
visitPutKeyValueCommand in interface Visitor- Overrides:
visitPutKeyValueCommand in class AbstractVisitor
- Throws:
Throwable
visitRemoveCommand
public Object visitRemoveCommand(InvocationContext ctx,
RemoveCommand command)
throws Throwable
- Specified by:
visitRemoveCommand in interface Visitor- Overrides:
visitRemoveCommand in class AbstractVisitor
- Throws:
Throwable
visitEvictCommand
public Object visitEvictCommand(InvocationContext ctx,
EvictCommand command)
throws Throwable
- Specified by:
visitEvictCommand in interface Visitor- Overrides:
visitEvictCommand in class AbstractVisitor
- Throws:
Throwable
visitGetKeyValueCommand
public Object visitGetKeyValueCommand(InvocationContext ctx,
GetKeyValueCommand command)
throws Throwable
- Specified by:
visitGetKeyValueCommand in interface Visitor- Overrides:
visitGetKeyValueCommand in class AbstractVisitor
- Throws:
Throwable
visitKeySetCommand
public Object visitKeySetCommand(InvocationContext ctx,
KeySetCommand command)
throws Throwable
- Specified by:
visitKeySetCommand in interface Visitor- Overrides:
visitKeySetCommand in class AbstractVisitor
- Throws:
Throwable
visitValuesCommand
public Object visitValuesCommand(InvocationContext ctx,
ValuesCommand command)
throws Throwable
- Specified by:
visitValuesCommand in interface Visitor- Overrides:
visitValuesCommand in class AbstractVisitor
- Throws:
Throwable
visitEntrySetCommand
public Object visitEntrySetCommand(InvocationContext ctx,
EntrySetCommand command)
throws Throwable
- Specified by:
visitEntrySetCommand in interface Visitor- Overrides:
visitEntrySetCommand in class AbstractVisitor
- Throws:
Throwable
visitReplaceCommand
public Object visitReplaceCommand(InvocationContext ctx,
ReplaceCommand command)
throws Throwable
- Specified by:
visitReplaceCommand in interface Visitor- Overrides:
visitReplaceCommand in class AbstractVisitor
- Throws:
Throwable
visitInvalidateCommand
public Object visitInvalidateCommand(InvocationContext ctx,
InvalidateCommand command)
throws Throwable
- Specified by:
visitInvalidateCommand in interface Visitor- Overrides:
visitInvalidateCommand in class AbstractVisitor
- Throws:
Throwable
wrapMap
protected Map wrapMap(Map<Object,Object> m,
Set<MarshalledValue> marshalledValues,
InvocationContext ctx)
throws NotSerializableException
- Throws:
NotSerializableException
createMarshalledValue
protected MarshalledValue createMarshalledValue(Object toWrap,
InvocationContext ctx)
throws NotSerializableException
- Throws:
NotSerializableException
Copyright © 2010 JBoss, a division of Red Hat. All Rights Reserved.