openikev2::TransformAttribute Class Reference

This class represents a transform attribute, used in a cryptographic suite negociation. More...

#include <transformattribute.h>

Inheritance diagram for openikev2::TransformAttribute:

Inheritance graph
[legend]
List of all members.

Public Member Functions

 TransformAttribute (Enums::ATTRIBUTE_TYPE type, uint16_t TVvalue)
 Creates a new TransformAttribute, in TV format.
 TransformAttribute (Enums::ATTRIBUTE_TYPE type, auto_ptr< ByteArray > TLVvalue)
 Creates a new TransformAttribute, in TLV format.
 TransformAttribute (ByteBuffer &byte_buffer)
 Creates a new TransformAttribute based on its binary representation.
virtual void getBinaryRepresentation (ByteBuffer &byte_buffer) const
 Appends the binary representation of the transform in the ByteBuffer.
virtual auto_ptr< TransformAttributeclone () const
 Clones this TransformAttribute.
virtual bool operator== (const TransformAttribute &other) const
 Compares if this TransformAttribute object is equal to other.
virtual string toStringTab (uint8_t tabs) const
 Construct a textual representation of the object, preceded of a num of tabs of size TAB_SIZE.

Public Attributes

auto_ptr< ByteArrayTLVvalue
 Attribute value (when using TLV format).
uint16_t TVvalue
 Attribute value (when using TV format).
bool isTV
 Attribute format (TLV or TV).
Enums::ATTRIBUTE_TYPE type
 Attribute type.

Detailed Description

This class represents a transform attribute, used in a cryptographic suite negociation.

Author:
Pedro J. Fernandez Ruiz, Alejandro Perez Mendez <pedroj.fernandez@dif.um.es, alejandro_perez@dif.um.es>


Constructor & Destructor Documentation

openikev2::TransformAttribute::TransformAttribute ( Enums::ATTRIBUTE_TYPE  type,
uint16_t  TVvalue 
)

Creates a new TransformAttribute, in TV format.

Parameters:
type Attribute type.
TVvalue Attribute value.

openikev2::TransformAttribute::TransformAttribute ( Enums::ATTRIBUTE_TYPE  type,
auto_ptr< ByteArray TLVvalue 
)

Creates a new TransformAttribute, in TLV format.

Parameters:
type Attribute type.
TLVvalue Attribute value.

openikev2::TransformAttribute::TransformAttribute ( ByteBuffer byte_buffer  ) 

Creates a new TransformAttribute based on its binary representation.

Parameters:
byte_buffer Buffer with its read pointer at the begin of a TransformAttribute


Member Function Documentation

void openikev2::TransformAttribute::getBinaryRepresentation ( ByteBuffer byte_buffer  )  const [virtual]

Appends the binary representation of the transform in the ByteBuffer.

Parameters:
byte_buffer ByteBuffer where append the binary representation

auto_ptr< TransformAttribute > openikev2::TransformAttribute::clone (  )  const [virtual]

Clones this TransformAttribute.

Returns:
A new TransformAttribute

bool openikev2::TransformAttribute::operator== ( const TransformAttribute other  )  const [virtual]

Compares if this TransformAttribute object is equal to other.

Parameters:
other The other TransformAttribute
Returns:
TRUE if both are equals, FALSE otherwise

string openikev2::TransformAttribute::toStringTab ( uint8_t  tabs  )  const [virtual]

Construct a textual representation of the object, preceded of a num of tabs of size TAB_SIZE.

Parameters:
tabs Num of tabs preceding the textual representation.
Returns:
Textual tabulated represetation of the object.

Implements openikev2::Printable.


Generated on Fri Jul 27 11:04:57 2007 for libopenikev2 by  doxygen 1.5.1