Main Page   Modules   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members   Related Pages  

ACEXML_Attribute Class Reference

ACEXML_Attribute defines the data structure of an attribute. More...

#include "ACEXML/common/AttributesImpl.h"

List of all members.

Public Methods

 ACEXML_Attribute (void)
 Default constructor. More...

 ACEXML_Attribute (const ACEXML_Attribute &attr)
 Copy constructor. More...

 ACEXML_Attribute (const ACEXML_Char *uri, const ACEXML_Char *localName, const ACEXML_Char *qName, const ACEXML_Char *type, const ACEXML_Char *value)
 Initialize all constructor. More...

 ~ACEXML_Attribute (void)
 Destructor. More...

void setAttribute (const ACEXML_Char *uri, const ACEXML_Char *localName, const ACEXML_Char *qName, const ACEXML_Char *type, const ACEXML_Char *value)
 Set all members. More...

const ACEXML_Charuri (void) const
 Get uri_. More...

void uri (const ACEXML_Char *uri)
 Set uri_. More...

const ACEXML_CharlocalName (void) const
 Get localName_. More...

void localName (const ACEXML_Char *localName)
 Set localName_. More...

const ACEXML_CharqName (void) const
 Get qName_. More...

void qName (const ACEXML_Char *qName)
 Set qName_. More...

const ACEXML_Chartype (void) const
 Get type_. More...

void type (const ACEXML_Char *type)
 Set type_. More...

const ACEXML_Charvalue (void) const
 Get value_. More...

void value (const ACEXML_Char *value)
 Set value_. More...

ACEXML_Attribute & operator= (const ACEXML_Attribute &rhs)
 Assignment operator. More...

int operator!= (const ACEXML_Attribute &rhs) const
 Comparison operator. More...


Private Attributes

ACEXML_Charuri_
 @var uri_ Namespace URI of an attribute. More...

ACEXML_CharlocalName_
 @var localName_. More...

ACEXML_CharqName_
ACEXML_Chartype_
ACEXML_Charvalue_

Friends

class ACEXML_AttributesImpl


Detailed Description

ACEXML_Attribute defines the data structure of an attribute.

See also:
ACEXML_AttributesImpl

Definition at line 40 of file AttributesImpl.h.


Constructor & Destructor Documentation

ACEXML_INLINE ACEXML_Attribute::ACEXML_Attribute void   
 

Default constructor.

Definition at line 6 of file AttributesImpl.i.

00007   : uri_ (0),
00008     localName_ (0),
00009     qName_ (0),
00010     type_ (0),
00011     value_ (0)
00012 {
00013 }

ACEXML_INLINE ACEXML_Attribute::ACEXML_Attribute const ACEXML_Attribute &    attr
 

Copy constructor.

Definition at line 16 of file AttributesImpl.i.

00017   : uri_ (ACE::strnew (attr.uri_)),
00018     localName_ (ACE::strnew (attr.localName_)),
00019     qName_ (ACE::strnew (attr.qName_)),
00020     type_ (ACE::strnew (attr.type_)),
00021     value_ (ACE::strnew (attr.value_))
00022 {
00023 }

ACEXML_INLINE ACEXML_Attribute::ACEXML_Attribute const ACEXML_Char   uri,
const ACEXML_Char   localName,
const ACEXML_Char   qName,
const ACEXML_Char   type,
const ACEXML_Char   value
 

Initialize all constructor.

Definition at line 26 of file AttributesImpl.i.

References ACEXML_Char.

00031   : uri_ (ACE::strnew (uri)),
00032     localName_ (ACE::strnew (localName)),
00033     qName_ (ACE::strnew (qName)),
00034     type_ (ACE::strnew (type)),
00035     value_ (ACE::strnew (value))
00036 {
00037 }

ACEXML_INLINE ACEXML_Attribute::~ACEXML_Attribute void   
 

Destructor.

Definition at line 40 of file AttributesImpl.i.

References localName_, qName_, type_, uri_, and value_.

00041 {
00042   delete[] this->uri_;
00043   delete[] this->localName_;
00044   delete[] this->qName_;
00045   delete[] this->type_;
00046   delete[] this->value_;
00047 }


Member Function Documentation

ACEXML_INLINE void ACEXML_Attribute::localName const ACEXML_Char   localName
 

Set localName_.

Definition at line 69 of file AttributesImpl.i.

References ACEXML_Char, localName, localName_, and ACE::strnew.

00070 {
00071   delete[] this->localName_;
00072   this->localName_ = ACE::strnew (localName);
00073 }

ACEXML_INLINE const ACEXML_Char * ACEXML_Attribute::localName void    const
 

Get localName_.

Definition at line 63 of file AttributesImpl.i.

References localName_.

Referenced by ACEXML_AttributesImpl::addAttribute, localName, operator!=, operator=, and setAttribute.

00064 {
00065   return this->localName_;
00066 }

ACEXML_INLINE int ACEXML_Attribute::operator!= const ACEXML_Attribute &    rhs const
 

Comparison operator.

Definition at line 143 of file AttributesImpl.i.

References localName, qName, ACE_OS_String::strcmp, type, uri, and value.

00144 {
00145   return (ACE_OS::strcmp (this->uri_, rhs.uri ()) == 0 &&
00146           ACE_OS::strcmp (this->localName_, rhs.localName ()) == 0 &&
00147           ACE_OS::strcmp (this->qName_, rhs .qName ()) == 0 &&
00148           ACE_OS::strcmp (this->type_, rhs.type ()) == 0 &&
00149           ACE_OS::strcmp (this->value_, rhs.value ()) == 0 ? 0 : 1);
00150 
00151 }

ACEXML_INLINE ACEXML_Attribute & ACEXML_Attribute::operator= const ACEXML_Attribute &    rhs
 

Assignment operator.

Definition at line 129 of file AttributesImpl.i.

References localName, qName, type, uri, and value.

00130 {
00131   if (this != &rhs)             // Check for self assignment
00132     {
00133       this->uri (rhs.uri ());
00134       this->qName (rhs.qName ());
00135       this->localName (rhs.localName ());
00136       this->type (rhs.type ());
00137       this->value (rhs.value ());
00138     }
00139   return *this;
00140 }

ACEXML_INLINE void ACEXML_Attribute::qName const ACEXML_Char   qName
 

Set qName_.

Definition at line 82 of file AttributesImpl.i.

References ACEXML_Char, qName, qName_, and ACE::strnew.

00083 {
00084   delete[] this->qName_;
00085   this->qName_ = ACE::strnew (qName);
00086 }

ACEXML_INLINE const ACEXML_Char * ACEXML_Attribute::qName void    const
 

Get qName_.

Definition at line 76 of file AttributesImpl.i.

References qName_.

Referenced by ACEXML_AttributesImpl::addAttribute, operator!=, operator=, qName, and setAttribute.

00077 {
00078   return this->qName_;
00079 }

ACEXML_INLINE void ACEXML_Attribute::setAttribute const ACEXML_Char   uri,
const ACEXML_Char   localName,
const ACEXML_Char   qName,
const ACEXML_Char   type,
const ACEXML_Char   value
 

Set all members.

Definition at line 115 of file AttributesImpl.i.

References ACEXML_Char, localName, qName, type, uri, and value.

00120 {
00121   this->uri (uri);
00122   this->qName (qName);
00123   this->localName (localName);
00124   this->type (type);
00125   this->value (value);
00126 }

ACEXML_INLINE void ACEXML_Attribute::type const ACEXML_Char   type
 

Set type_.

Definition at line 95 of file AttributesImpl.i.

References ACEXML_Char, ACE::strnew, type, and type_.

00096 {
00097   delete[] this->type_;
00098   this->type_ = ACE::strnew (type);
00099 }

ACEXML_INLINE const ACEXML_Char * ACEXML_Attribute::type void    const
 

Get type_.

Definition at line 89 of file AttributesImpl.i.

References type_.

Referenced by operator!=, operator=, setAttribute, and type.

00090 {
00091   return this->type_;
00092 }

ACEXML_INLINE void ACEXML_Attribute::uri const ACEXML_Char   uri
 

Set uri_.

Definition at line 56 of file AttributesImpl.i.

References ACEXML_Char, ACE::strnew, uri, and uri_.

00057 {
00058   delete[] this->uri_;
00059   this->uri_ = ACE::strnew (uri);
00060 }

ACEXML_INLINE const ACEXML_Char * ACEXML_Attribute::uri void    const
 

Get uri_.

Definition at line 50 of file AttributesImpl.i.

References uri_.

Referenced by ACEXML_AttributesImpl::addAttribute, operator!=, operator=, setAttribute, and uri.

00051 {
00052   return this->uri_;
00053 }

ACEXML_INLINE void ACEXML_Attribute::value const ACEXML_Char   value
 

Set value_.

Definition at line 108 of file AttributesImpl.i.

References ACEXML_Char, ACE::strnew, value, and value_.

00109 {
00110   delete[] this->value_;
00111   this->value_ = ACE::strnew (value);
00112 }

ACEXML_INLINE const ACEXML_Char * ACEXML_Attribute::value void    const
 

Get value_.

Definition at line 102 of file AttributesImpl.i.

References value_.

Referenced by operator!=, operator=, setAttribute, and value.

00103 {
00104   return this->value_;
00105 }


Friends And Related Function Documentation

friend class ACEXML_AttributesImpl [friend]
 

Definition at line 43 of file AttributesImpl.h.


Member Data Documentation

ACEXML_Char* ACEXML_Attribute::localName_ [private]
 

@var localName_.

Definition at line 109 of file AttributesImpl.h.

Referenced by localName, and ~ACEXML_Attribute.

ACEXML_Char* ACEXML_Attribute::qName_ [private]
 

Definition at line 110 of file AttributesImpl.h.

Referenced by qName, and ~ACEXML_Attribute.

ACEXML_Char* ACEXML_Attribute::type_ [private]
 

Definition at line 111 of file AttributesImpl.h.

Referenced by type, and ~ACEXML_Attribute.

ACEXML_Char* ACEXML_Attribute::uri_ [private]
 

@var uri_ Namespace URI of an attribute.

Definition at line 106 of file AttributesImpl.h.

Referenced by uri, and ~ACEXML_Attribute.

ACEXML_Char* ACEXML_Attribute::value_ [private]
 

Definition at line 112 of file AttributesImpl.h.

Referenced by value, and ~ACEXML_Attribute.


The documentation for this class was generated from the following files:
Generated on Mon Jun 16 13:26:29 2003 for ACEXML by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002