org.jboss.narayana.blacktie.jatmibroker.xatmi.impl
Class X_COMMON_Impl

java.lang.Object
  extended by org.jboss.narayana.blacktie.jatmibroker.xatmi.impl.BufferImpl
      extended by org.jboss.narayana.blacktie.jatmibroker.xatmi.impl.X_COMMON_Impl
All Implemented Interfaces:
Serializable, Buffer, X_COMMON

public class X_COMMON_Impl
extends BufferImpl
implements X_COMMON

The X_COMMON buffer type supports a subset of the types provided by the X_C_TYPE buffer in order to support more language portable data exchange.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.jboss.narayana.blacktie.jatmibroker.xatmi.impl.BufferImpl
BYTE_SIZE, DOUBLE_SIZE, FLOAT_SIZE, INT_SIZE, len, LONG_SIZE, SHORT_SIZE
 
Constructor Summary
X_COMMON_Impl(String subtype)
          The constructor is hidden as a Connection should be used to allocate the object.
 
Method Summary
 byte getByte(String key)
           
 byte[] getByteArray(String key)
           
 long getLong(String key)
           
 long[] getLongArray(String key)
           
 short getShort(String key)
          Get the short value identified by the key.
 short[] getShortArray(String key)
           
 void setByte(String key, byte value)
           
 void setByteArray(String key, byte[] value)
           
 void setLong(String key, long value)
           
 void setLongArray(String key, long[] value)
           
 void setShort(String key, short value)
          Set the short value
 void setShortArray(String key, short[] value)
           
 
Methods inherited from class org.jboss.narayana.blacktie.jatmibroker.xatmi.impl.BufferImpl
clear, deserialize, getAttributeValue, getFormat, getLen, getRawData, getSubtype, getType, serialize, setAttributeValue, setRawData
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.jboss.narayana.blacktie.jatmibroker.xatmi.Buffer
getLen, getSubtype, getType
 

Constructor Detail

X_COMMON_Impl

public X_COMMON_Impl(String subtype)
              throws ConnectionException,
                     org.jboss.narayana.blacktie.jatmibroker.core.conf.ConfigurationException
The constructor is hidden as a Connection should be used to allocate the object.

Parameters:
subtype - The subtype of the buffer, must be registered in the configuration
properties - The properties to use
Throws:
ConnectionException - In case the buffer cannot be created.
org.jboss.narayana.blacktie.jatmibroker.core.conf.ConfigurationException
See Also:
ConnectionImpl#tpalloc(String, String)}
Method Detail

getShort

public short getShort(String key)
               throws ConnectionException
Get the short value identified by the key.

Specified by:
getShort in interface X_COMMON
Parameters:
key - The key to use
Returns:
The short value
Throws:
ConnectionException - In case the key is not part of the structure.

setShort

public void setShort(String key,
                     short value)
              throws ConnectionException
Set the short value

Specified by:
setShort in interface X_COMMON
Parameters:
key - The value to set
value - The value to use
Throws:
ConnectionException - In case the key is unknown.

getLong

public long getLong(String key)
             throws ConnectionException
Specified by:
getLong in interface X_COMMON
Throws:
ConnectionException

setLong

public void setLong(String key,
                    long value)
             throws ConnectionException
Specified by:
setLong in interface X_COMMON
Throws:
ConnectionException

getByte

public byte getByte(String key)
             throws ConnectionException
Specified by:
getByte in interface X_COMMON
Throws:
ConnectionException

setByte

public void setByte(String key,
                    byte value)
             throws ConnectionException
Specified by:
setByte in interface X_COMMON
Throws:
ConnectionException

getShortArray

public short[] getShortArray(String key)
                      throws ConnectionException
Specified by:
getShortArray in interface X_COMMON
Throws:
ConnectionException

setShortArray

public void setShortArray(String key,
                          short[] value)
                   throws ConnectionException
Specified by:
setShortArray in interface X_COMMON
Throws:
ConnectionException

getLongArray

public long[] getLongArray(String key)
                    throws ConnectionException
Specified by:
getLongArray in interface X_COMMON
Throws:
ConnectionException

setLongArray

public void setLongArray(String key,
                         long[] value)
                  throws ConnectionException
Specified by:
setLongArray in interface X_COMMON
Throws:
ConnectionException

getByteArray

public byte[] getByteArray(String key)
                    throws ConnectionException
Specified by:
getByteArray in interface X_COMMON
Throws:
ConnectionException

setByteArray

public void setByteArray(String key,
                         byte[] value)
                  throws ConnectionException
Specified by:
setByteArray in interface X_COMMON
Throws:
ConnectionException


Copyright © 2013. All Rights Reserved.