Back to index

salome-kernel  6.5.0
Public Member Functions
SALOMEDS_AttributeParameter_i Class Reference

Class: SALOMEDS_AttributeParameter Description : AttributeParameter is a universal container of basic types. More...

#include <SALOMEDS_AttributeParameter_i.hxx>

List of all members.

Public Member Functions

 SALOMEDS_AttributeParameter_i (SALOMEDSImpl_AttributeParameter *theAttr, CORBA::ORB_ptr orb)
 ~SALOMEDS_AttributeParameter_i ()
virtual void SetInt (const char *theID, CORBA::Long theValue)
 Function : SetInt Purpose : Associates a integer value with the ID.
virtual CORBA::Long GetInt (const char *theID) throw (SALOMEDS::AttributeParameter::InvalidIdentifier)
 Function : GetInt Purpose : Returns a int value associated with the given ID.
virtual void SetReal (const char *theID, CORBA::Double theValue)
 Function : SetReal Purpose : Associates a double value with the ID.
virtual CORBA::Double GetReal (const char *theID) throw (SALOMEDS::AttributeParameter::InvalidIdentifier)
 Function : GetReal Purpose : Returns a double value associated with the given ID.
virtual void SetString (const char *theID, const char *theValue)
 Function : SetString Purpose : Associates a string with the ID.
virtual char * GetString (const char *theID) throw (SALOMEDS::AttributeParameter::InvalidIdentifier)
 Function : GetString Purpose : Returns a string associated with the given ID.
virtual void SetBool (const char *theID, CORBA::Boolean theValue)
 Function : SetBool Purpose : Associates a bool value with the ID.
virtual CORBA::Boolean GetBool (const char *theID) throw (SALOMEDS::AttributeParameter::InvalidIdentifier)
 Function : GetBool Purpose : Returns a bool value associated with the ID.
virtual void SetRealArray (const char *theID, const SALOMEDS::DoubleSeq &theArray)
 Function : SetRealArray Purpose : Associates an array of double values with the given ID.
virtual SALOMEDS::DoubleSeqGetRealArray (const char *theID) throw (SALOMEDS::AttributeParameter::InvalidIdentifier)
 Function : GetRealArray Purpose : Returns an array of double values associated with the ID.
virtual void SetIntArray (const char *theID, const SALOMEDS::LongSeq &theArray)
 Function : SetIntArray Purpose : Associates an array of int values with the given ID.
virtual SALOMEDS::LongSeqGetIntArray (const char *theID) throw (SALOMEDS::AttributeParameter::InvalidIdentifier)
 Function : GetIntArray Purpose : Returns an array of int values associated with the ID.
virtual void SetStrArray (const char *theID, const SALOMEDS::StringSeq &theArray)
 Function : SetStrArray Purpose : Associates an array of string values with the given ID.
virtual SALOMEDS::StringSeqGetStrArray (const char *theID) throw (SALOMEDS::AttributeParameter::InvalidIdentifier)
 Function : GetStrArray Purpose : Returns an array of string values associated with the ID.
virtual CORBA::Boolean IsSet (const char *theID, CORBA::Long theType)
 Function : IsSet Purpose : Returns true if for the ID of given type was assigned
a value in the attribute.
virtual CORBA::Boolean RemoveID (const char *theID, CORBA::Long theType)
 Function : RemoveID Purpose : Removes a parameter with given ID.
virtual
SALOMEDS::AttributeParameter_ptr 
GetFather ()
 Function : GetFather Purpose : Returns a father attribute for this attribute.
virtual CORBA::Boolean HasFather ()
 Function : HasFather Purpose : Returns True if the attribute has a father attribute.
virtual CORBA::Boolean IsRoot ()
 Function : IsRoot Purpose : Returns True is the attribute is highest in an hierachy.
virtual void Clear ()
 Function : IsRoot Purpose : Clears the content of the attribute.
virtual SALOMEDS::StringSeqGetIDs (CORBA::Long theType)
 Function : GetIDs Purpose : Returns an array of all ID's of the given type.

Detailed Description

Class: SALOMEDS_AttributeParameter Description : AttributeParameter is a universal container of basic types.

Definition at line 43 of file SALOMEDS_AttributeParameter_i.hxx.


Constructor & Destructor Documentation

SALOMEDS_AttributeParameter_i::SALOMEDS_AttributeParameter_i ( SALOMEDSImpl_AttributeParameter *  theAttr,
CORBA::ORB_ptr  orb 
) [inline]

Definition at line 48 of file SALOMEDS_AttributeParameter_i.hxx.

    :SALOMEDS_GenericAttribute_i(theAttr, orb) {}; 

Here is the caller graph for this function:

Definition at line 51 of file SALOMEDS_AttributeParameter_i.hxx.

{};

Member Function Documentation

Function : IsRoot Purpose : Clears the content of the attribute.

Definition at line 337 of file SALOMEDS_AttributeParameter_i.cxx.

{
  SALOMEDS::Locker lock; 
  dynamic_cast<SALOMEDSImpl_AttributeParameter*>(_impl)->Clear();
}

Here is the call graph for this function:

CORBA::Boolean SALOMEDS_AttributeParameter_i::GetBool ( const char *  theID) throw (SALOMEDS::AttributeParameter::InvalidIdentifier) [virtual]

Function : GetBool Purpose : Returns a bool value associated with the ID.

Definition at line 138 of file SALOMEDS_AttributeParameter_i.cxx.

{
  SALOMEDS::Locker lock; 
  Unexpect aCatch (AP_InvalidIdentifier);
  return dynamic_cast<SALOMEDSImpl_AttributeParameter*>(_impl)->GetBool(theID);
}

Here is the call graph for this function:

SALOMEDS::AttributeParameter_ptr SALOMEDS_AttributeParameter_i::GetFather ( ) [virtual]

Function : GetFather Purpose : Returns a father attribute for this attribute.

Definition at line 299 of file SALOMEDS_AttributeParameter_i.cxx.

{
  SALOMEDS::Locker lock; 
  SALOMEDSImpl_AttributeParameter* impl = dynamic_cast<SALOMEDSImpl_AttributeParameter*>(_impl);
  SALOMEDS_AttributeParameter_i* attr = new SALOMEDS_AttributeParameter_i(impl, _orb);
  return attr->AttributeParameter::_this();
}

Here is the call graph for this function:

SALOMEDS::StringSeq * SALOMEDS_AttributeParameter_i::GetIDs ( CORBA::Long  theType) [virtual]

Function : GetIDs Purpose : Returns an array of all ID's of the given type.

Definition at line 350 of file SALOMEDS_AttributeParameter_i.cxx.

{
  SALOMEDS::Locker lock; 
  SALOMEDS::StringSeq_var CorbaSeq = new SALOMEDS::StringSeq;
  std::vector<std::string> A = dynamic_cast<SALOMEDSImpl_AttributeParameter*>(_impl)->GetIDs((Parameter_Types)theType);

  if(A.size()) {
    int length = A.size();
    CorbaSeq->length(length);
    for (int i = 0; i < length; i++) CorbaSeq[i] = CORBA::string_dup(A[i].c_str());;
  }

  return CorbaSeq._retn();
}

Here is the call graph for this function:

CORBA::Long SALOMEDS_AttributeParameter_i::GetInt ( const char *  theID) throw (SALOMEDS::AttributeParameter::InvalidIdentifier) [virtual]

Function : GetInt Purpose : Returns a int value associated with the given ID.

Definition at line 54 of file SALOMEDS_AttributeParameter_i.cxx.

{
  SALOMEDS::Locker lock; 
  Unexpect aCatch (AP_InvalidIdentifier);
  return dynamic_cast<SALOMEDSImpl_AttributeParameter*>(_impl)->GetInt(theID);
}

Here is the call graph for this function:

Function : GetIntArray Purpose : Returns an array of int values associated with the ID.

Definition at line 211 of file SALOMEDS_AttributeParameter_i.cxx.

{
  SALOMEDS::Locker lock; 
  Unexpect aCatch (AP_InvalidIdentifier);
  SALOMEDS::LongSeq_var aSeq = new SALOMEDS::LongSeq;
  std::vector<int> v = dynamic_cast<SALOMEDSImpl_AttributeParameter*>(_impl)->GetIntArray(theID);
  int length = v.size();
  if(length) {
    aSeq->length(length);
    for(int i = 0; i<length; i++) aSeq[i] = v[i];
  }
  return aSeq._retn();
}

Here is the call graph for this function:

CORBA::Double SALOMEDS_AttributeParameter_i::GetReal ( const char *  theID) throw (SALOMEDS::AttributeParameter::InvalidIdentifier) [virtual]

Function : GetReal Purpose : Returns a double value associated with the given ID.

Definition at line 81 of file SALOMEDS_AttributeParameter_i.cxx.

{
  SALOMEDS::Locker lock; 
  Unexpect aCatch (AP_InvalidIdentifier);
  return dynamic_cast<SALOMEDSImpl_AttributeParameter*>(_impl)->GetReal(theID);
}

Here is the call graph for this function:

Function : GetRealArray Purpose : Returns an array of double values associated with the ID.

Definition at line 171 of file SALOMEDS_AttributeParameter_i.cxx.

{
  SALOMEDS::Locker lock; 
  Unexpect aCatch (AP_InvalidIdentifier);
  SALOMEDS::DoubleSeq_var aSeq = new SALOMEDS::DoubleSeq;
  std::vector<double> v = dynamic_cast<SALOMEDSImpl_AttributeParameter*>(_impl)->GetRealArray(theID);
  int length = v.size();
  if(length) {
    aSeq->length(length);
    for(int i = 0; i<length; i++) aSeq[i] = v[i];
  }
  return aSeq._retn();
}

Here is the call graph for this function:

Function : GetStrArray Purpose : Returns an array of string values associated with the ID.

Definition at line 251 of file SALOMEDS_AttributeParameter_i.cxx.

{
  SALOMEDS::Locker lock; 
  Unexpect aCatch (AP_InvalidIdentifier);
  SALOMEDS::StringSeq_var aSeq = new SALOMEDS::StringSeq;
  std::vector<std::string> v = dynamic_cast<SALOMEDSImpl_AttributeParameter*>(_impl)->GetStrArray(theID);
  int length = v.size();
  if(length) {
    aSeq->length(length);
    for(int i = 0; i<length; i++) aSeq[i] = CORBA::string_dup(v[i].c_str());
  }
  return aSeq._retn();
}

Here is the call graph for this function:

Function : GetString Purpose : Returns a string associated with the given ID.

Definition at line 109 of file SALOMEDS_AttributeParameter_i.cxx.

{
  SALOMEDS::Locker lock; 
  Unexpect aCatch (AP_InvalidIdentifier);
  SALOMEDSImpl_AttributeParameter* impl = dynamic_cast<SALOMEDSImpl_AttributeParameter*>(_impl);
  CORBA::String_var c_s = CORBA::string_dup(impl->GetString(theID).c_str());
  return c_s._retn();
}

Here is the call graph for this function:

CORBA::Boolean SALOMEDS_AttributeParameter_i::HasFather ( ) [virtual]

Function : HasFather Purpose : Returns True if the attribute has a father attribute.

Definition at line 313 of file SALOMEDS_AttributeParameter_i.cxx.

{
  SALOMEDS::Locker lock; 
  return dynamic_cast<SALOMEDSImpl_AttributeParameter*>(_impl)->HasFather();
}

Here is the call graph for this function:

CORBA::Boolean SALOMEDS_AttributeParameter_i::IsRoot ( ) [virtual]

Function : IsRoot Purpose : Returns True is the attribute is highest in an hierachy.

Definition at line 325 of file SALOMEDS_AttributeParameter_i.cxx.

{
  SALOMEDS::Locker lock; 
  return dynamic_cast<SALOMEDSImpl_AttributeParameter*>(_impl)->IsRoot();
}

Here is the call graph for this function:

CORBA::Boolean SALOMEDS_AttributeParameter_i::IsSet ( const char *  theID,
CORBA::Long  theType 
) [virtual]

Function : IsSet Purpose : Returns true if for the ID of given type was assigned
a value in the attribute.

Definition at line 274 of file SALOMEDS_AttributeParameter_i.cxx.

{
  SALOMEDS::Locker lock; 
  return dynamic_cast<SALOMEDSImpl_AttributeParameter*>(_impl)->IsSet(theID, (Parameter_Types)theType);
}

Here is the call graph for this function:

CORBA::Boolean SALOMEDS_AttributeParameter_i::RemoveID ( const char *  theID,
CORBA::Long  theType 
) [virtual]

Function : RemoveID Purpose : Removes a parameter with given ID.

Definition at line 286 of file SALOMEDS_AttributeParameter_i.cxx.

{
  SALOMEDS::Locker lock; 
  CheckLocked();
  return dynamic_cast<SALOMEDSImpl_AttributeParameter*>(_impl)->RemoveID(theID, (Parameter_Types)theType);
}

Here is the call graph for this function:

void SALOMEDS_AttributeParameter_i::SetBool ( const char *  theID,
CORBA::Boolean  theValue 
) [virtual]

Function : SetBool Purpose : Associates a bool value with the ID.

Definition at line 125 of file SALOMEDS_AttributeParameter_i.cxx.

{
  SALOMEDS::Locker lock; 
  CheckLocked();
  dynamic_cast<SALOMEDSImpl_AttributeParameter*>(_impl)->SetBool(theID, theValue);
}

Here is the call graph for this function:

void SALOMEDS_AttributeParameter_i::SetInt ( const char *  theID,
CORBA::Long  theValue 
) [virtual]

Function : SetInt Purpose : Associates a integer value with the ID.

Definition at line 41 of file SALOMEDS_AttributeParameter_i.cxx.

{
  SALOMEDS::Locker lock; 
  CheckLocked();
  dynamic_cast<SALOMEDSImpl_AttributeParameter*>(_impl)->SetInt(theID, theValue);
}

Here is the call graph for this function:

void SALOMEDS_AttributeParameter_i::SetIntArray ( const char *  theID,
const SALOMEDS::LongSeq theArray 
) [virtual]

Function : SetIntArray Purpose : Associates an array of int values with the given ID.

Definition at line 192 of file SALOMEDS_AttributeParameter_i.cxx.

{
  SALOMEDS::Locker lock; 
  CheckLocked();
  std::vector<int> v;
  int length = theArray.length();
  if(length) {
    v.resize(length);
    for(int i = 0; i<length; i++) v[i] = theArray[i];
  }
  dynamic_cast<SALOMEDSImpl_AttributeParameter*>(_impl)->SetIntArray(theID, v);
}

Here is the call graph for this function:

void SALOMEDS_AttributeParameter_i::SetReal ( const char *  theID,
CORBA::Double  theValue 
) [virtual]

Function : SetReal Purpose : Associates a double value with the ID.

Definition at line 68 of file SALOMEDS_AttributeParameter_i.cxx.

{
  SALOMEDS::Locker lock; 
  CheckLocked();
  dynamic_cast<SALOMEDSImpl_AttributeParameter*>(_impl)->SetReal(theID, theValue);
}

Here is the call graph for this function:

void SALOMEDS_AttributeParameter_i::SetRealArray ( const char *  theID,
const SALOMEDS::DoubleSeq theArray 
) [virtual]

Function : SetRealArray Purpose : Associates an array of double values with the given ID.

Definition at line 152 of file SALOMEDS_AttributeParameter_i.cxx.

{
  SALOMEDS::Locker lock; 
  CheckLocked();
  std::vector<double> v;
  int length = theArray.length();
  if(length) {
    v.resize(length);
    for(int i = 0; i<length; i++) v[i] = theArray[i];
  }
  dynamic_cast<SALOMEDSImpl_AttributeParameter*>(_impl)->SetRealArray(theID, v);
}

Here is the call graph for this function:

void SALOMEDS_AttributeParameter_i::SetStrArray ( const char *  theID,
const SALOMEDS::StringSeq theArray 
) [virtual]

Function : SetStrArray Purpose : Associates an array of string values with the given ID.

Definition at line 232 of file SALOMEDS_AttributeParameter_i.cxx.

{
  SALOMEDS::Locker lock; 
  CheckLocked();
  std::vector<std::string> v;
  int length = theArray.length();
  if(length) {
    v.resize(length);
    for(int i = 0; i<length; i++) v[i] = std::string(theArray[i].in());
  }
  dynamic_cast<SALOMEDSImpl_AttributeParameter*>(_impl)->SetStrArray(theID, v);
}

Here is the call graph for this function:

void SALOMEDS_AttributeParameter_i::SetString ( const char *  theID,
const char *  theValue 
) [virtual]

Function : SetString Purpose : Associates a string with the ID.

Definition at line 95 of file SALOMEDS_AttributeParameter_i.cxx.

{
  SALOMEDS::Locker lock; 
  CheckLocked();
  SALOMEDSImpl_AttributeParameter* impl = dynamic_cast<SALOMEDSImpl_AttributeParameter*>(_impl);
  impl->SetString(theID, theValue);
}

Here is the call graph for this function:


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