com.hazelcast.web
Class InvalidateSessionAttributesEntryProcessor

java.lang.Object
  extended by com.hazelcast.map.AbstractEntryProcessor<String,T>
      extended by com.hazelcast.web.AbstractWebDataEntryProcessor<Object>
          extended by com.hazelcast.web.InvalidateSessionAttributesEntryProcessor
All Implemented Interfaces:
EntryProcessor<String,Object>, DataSerializable, IdentifiedDataSerializable, Serializable

public class InvalidateSessionAttributesEntryProcessor
extends AbstractWebDataEntryProcessor<Object>

Invalidates all attributes for a destroyed session, removing them from the clustered map.

See Also:
Serialized Form

Constructor Summary
InvalidateSessionAttributesEntryProcessor()
           
InvalidateSessionAttributesEntryProcessor(String sessionId)
           
 
Method Summary
 int getId()
          Returns type identifier for this class.
 Object process(Map.Entry<String,Object> entry)
          Process the entry without worrying about concurrency.
 void readData(ObjectDataInput in)
          Reads fields from the input stream
 void writeData(ObjectDataOutput out)
          Writes object fields to output stream
 
Methods inherited from class com.hazelcast.web.AbstractWebDataEntryProcessor
getFactoryId
 
Methods inherited from class com.hazelcast.map.AbstractEntryProcessor
getBackupProcessor
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

InvalidateSessionAttributesEntryProcessor

public InvalidateSessionAttributesEntryProcessor()

InvalidateSessionAttributesEntryProcessor

public InvalidateSessionAttributesEntryProcessor(String sessionId)
Method Detail

getId

public int getId()
Description copied from interface: IdentifiedDataSerializable
Returns type identifier for this class. Id should be unique per DataSerializableFactory.

Returns:
type id

process

public Object process(Map.Entry<String,Object> entry)
Description copied from interface: EntryProcessor
Process the entry without worrying about concurrency.

Note that to modify an entry by using EntryProcessor you should explicitly call Map.Entry.setValue(V) method of Map.Entry such as:

 
 Override
        public Object process(Map.Entry entry) {
          Value value = entry.getValue();
          // process and modify value
          // ...
          entry.setValue(value);
          return result;
        }
 
 
otherwise EntryProcessor does not guarantee to modify the entry.

Parameters:
entry - entry to be processed
Returns:
result of the process

readData

public void readData(ObjectDataInput in)
              throws IOException
Description copied from interface: DataSerializable
Reads fields from the input stream

Specified by:
readData in interface DataSerializable
Overrides:
readData in class AbstractWebDataEntryProcessor<Object>
Parameters:
in - input
Throws:
IOException

writeData

public void writeData(ObjectDataOutput out)
               throws IOException
Description copied from interface: DataSerializable
Writes object fields to output stream

Specified by:
writeData in interface DataSerializable
Overrides:
writeData in class AbstractWebDataEntryProcessor<Object>
Parameters:
out - output
Throws:
IOException


Copyright © 2015 Hazelcast, Inc.. All Rights Reserved.