Version: 8.3.0
YACS::ENGINE::ComposedAny Class Referenceabstract

#include <Any.hxx>

Inheritance diagram for YACS::ENGINE::ComposedAny:
Collaboration diagram for YACS::ENGINE::ComposedAny:

Public Member Functions

virtual void setEltAtRank (int i, const Any *elem)=0 throw (Exception)
 
AnyPtr operator[] (const char *key) const throw (Exception)
 
- Public Member Functions inherited from YACS::ENGINE::Any
const TypeCodegetType () const
 
virtual Anyclone () const =0
 
virtual AnyPtr operator[] (int i) const =0 throw (Exception)
 
virtual bool operator== (const Any &other) const =0
 
- Public Member Functions inherited from YACS::ENGINE::RefCounter
unsigned int getRefCnt () const
 
void incrRef () const
 
bool decrRef ()
 

Protected Member Functions

 ComposedAny (const ComposedAny &other)
 
 ComposedAny (TypeCode *type, bool isNew=true)
 
void checkTypeOf (const Any *elem) const throw (Exception)
 
- Protected Member Functions inherited from YACS::ENGINE::Any
virtual ~Any ()
 
 Any (TypeCode *type)
 
 Any (const Any &other)
 
virtual void putMyReprAtPlace (char *data) const =0
 
- Protected Member Functions inherited from YACS::ENGINE::RefCounter
 RefCounter ()
 
 RefCounter (const RefCounter &other)
 
virtual ~RefCounter ()
 

Private Member Functions

int getIntValue () const throw (Exception)
 
bool getBoolValue () const throw (Exception)
 
double getDoubleValue () const throw (Exception)
 
std::string getStringValue () const throw (Exception)
 

Additional Inherited Members

- Static Public Attributes inherited from YACS::ENGINE::RefCounter
static unsigned int _totalCnt =0
 
- Static Protected Member Functions inherited from YACS::ENGINE::Any
static bool IsNull (char *data)
 
- Protected Attributes inherited from YACS::ENGINE::Any
TypeCode_type
 

Detailed Description

Definition at line 171 of file Any.hxx.

Constructor & Destructor Documentation

ComposedAny::ComposedAny ( const ComposedAny other)
protected

Definition at line 315 of file Any.cxx.

315  :Any(other)
316 {
317 }
ComposedAny::ComposedAny ( TypeCode type,
bool  isNew = true 
)
protected

Definition at line 319 of file Any.cxx.

References YACS::ENGINE::Any::_type, and YACS::ENGINE::RefCounter::decrRef().

319  :Any(type)
320 {
321  if(isNew)
322  _type->decrRef();
323 }

Member Function Documentation

void ComposedAny::checkTypeOf ( const Any elem) const throw (Exception)
protected

Definition at line 330 of file Any.cxx.

331 {
332  if(!elem->getType()->isA(_type->contentType()))
333  throw Exception("ComposedAny::checkTypeOf : invalid type.");
334 }
bool ComposedAny::getBoolValue ( ) const throw (Exception)
privatevirtual
double ComposedAny::getDoubleValue ( ) const throw (Exception)
privatevirtual
int ComposedAny::getIntValue ( ) const throw (Exception)
privatevirtual
std::string ComposedAny::getStringValue ( ) const throw (Exception)
privatevirtual
AnyPtr ComposedAny::operator[] ( const char *  key) const throw (Exception)
virtual

Implements YACS::ENGINE::Any.

Reimplemented in YACS::ENGINE::StructAny.

Definition at line 325 of file Any.cxx.

326 {
327  throw Exception("AtomAny::operator[] : try to get a part of a partitionned data not localizable by a string.");
328 }
virtual void YACS::ENGINE::ComposedAny::setEltAtRank ( int  i,
const Any elem 
) throw (Exception)
pure virtual

The documentation for this class was generated from the following files: