org.idoox.wasp.serialization
Interface SerializationChain


public interface SerializationChain

This class represents a chain of serializers.

Since:
3.2
Component:
Core

Method Summary
 Serializer getNextSerializerAs(java.lang.String serializerType)
          returns the next serializer converted to the type specified via serializerType attribute.
 java.lang.String getNextSerializersType()
          returns the jax-rpc type of the first serializer
 boolean hasMoreSerializers()
          returns true if there are any serializers left in the chain
 void removeSerializer(Serializer serializer)
          removes serializer from the chain, so that it won't be returned by getSerializerAs(...)
 

Method Detail

removeSerializer

public void removeSerializer(Serializer serializer)
removes serializer from the chain, so that it won't be returned by getSerializerAs(...)

Parameters:
serializer - the serializer to be removed

hasMoreSerializers

public boolean hasMoreSerializers()
returns true if there are any serializers left in the chain

Returns:
true if there is at least one serializer in the chain, false otherwise.

getNextSerializersType

public java.lang.String getNextSerializersType()
                                        throws java.util.NoSuchElementException
returns the jax-rpc type of the first serializer

Returns:
the jax-rpc type of the first serializer, estimated by calling getMechanismType() on the serializer.
Throws:
java.util.NoSuchElementException - if the chain is empty.

getNextSerializerAs

public Serializer getNextSerializerAs(java.lang.String serializerType)
                               throws java.util.NoSuchElementException
returns the next serializer converted to the type specified via serializerType attribute.

Returns:
the next serializer
Throws:
java.util.NoSuchElementException - if the chain is empty.