g4tools  5.4.0
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
tools::wroot::leaf_element Class Reference
Inheritance diagram for tools::wroot::leaf_element:
Inheritance graph
[legend]
Collaboration diagram for tools::wroot::leaf_element:
Collaboration graph
[legend]

Public Member Functions

virtual void * cast (cid a_class) const
 
virtual cid id_cls () const
 
virtual const std::string & store_cls () const
 
virtual bool stream (buffer &a_buffer) const
 
virtual bool fill_buffer (buffer &) const
 
 leaf_element (std::ostream &a_out, const std::string &a_name, int a_id, int a_type)
 
virtual ~leaf_element ()
 
- Public Member Functions inherited from tools::wroot::base_leaf
 base_leaf (std::ostream &a_out, const std::string &a_name, const std::string &a_title)
 
virtual ~base_leaf ()
 
const std::string & name () const
 
void set_title (const std::string &a_value)
 
uint32 length () const
 
void set_length (uint32 a_value)
 
void set_is_range (bool a_value)
 
- Public Member Functions inherited from tools::wroot::ibo
virtual ~ibo ()
 

Static Public Member Functions

static cid id_class ()
 
- Static Public Member Functions inherited from tools::wroot::base_leaf
static cid id_class ()
 

Protected Member Functions

 leaf_element (const leaf_element &a_from)
 
leaf_elementoperator= (const leaf_element &a_from)
 
- Protected Member Functions inherited from tools::wroot::base_leaf
 base_leaf (const base_leaf &a_from)
 
base_leafoperator= (const base_leaf &)
 

Protected Attributes

int fID
 
int fType
 
- Protected Attributes inherited from tools::wroot::base_leaf
std::ostream & m_out
 
std::string m_name
 
std::string m_title
 
uint32 m_length
 
uint32 m_length_type
 
ibom_leaf_count
 
bool m_is_range
 

Detailed Description

Definition at line 266 of file leaf.

Constructor & Destructor Documentation

◆ leaf_element() [1/2]

tools::wroot::leaf_element::leaf_element ( std::ostream &  a_out,
const std::string &  a_name,
int  a_id,
int  a_type 
)
inline

Definition at line 294 of file leaf.

295  :parent(a_out,a_name,a_name)
296  ,fID(a_id)
297  ,fType(a_type)
298  {}

◆ ~leaf_element()

virtual tools::wroot::leaf_element::~leaf_element ( )
inlinevirtual

Definition at line 299 of file leaf.

299 {}

◆ leaf_element() [2/2]

tools::wroot::leaf_element::leaf_element ( const leaf_element a_from)
inlineprotected

Definition at line 301 of file leaf.

301 :ibo(a_from),parent(a_from){}

Member Function Documentation

◆ cast()

virtual void* tools::wroot::leaf_element::cast ( cid  a_class) const
inlinevirtual

Reimplemented from tools::wroot::base_leaf.

Definition at line 270 of file leaf.

270  {
271  if(void* p = cmp_cast<leaf_element>(this,a_class)) {return p;}
272  return base_leaf::cast(a_class);
273  }

◆ fill_buffer()

virtual bool tools::wroot::leaf_element::fill_buffer ( buffer ) const
inlinevirtual

Implements tools::wroot::base_leaf.

Definition at line 289 of file leaf.

289  {
290  m_out << "tools::wroot::leaf_element::fill_buffer : dummy." << std::endl;
291  return false;
292  }

◆ id_class()

static cid tools::wroot::leaf_element::id_class ( )
inlinestatic

Definition at line 269 of file leaf.

269 {return leaf_element_cid();}

◆ id_cls()

virtual cid tools::wroot::leaf_element::id_cls ( ) const
inlinevirtual

Reimplemented from tools::wroot::base_leaf.

Definition at line 274 of file leaf.

274 {return id_class();}

◆ operator=()

leaf_element& tools::wroot::leaf_element::operator= ( const leaf_element a_from)
inlineprotected

Definition at line 302 of file leaf.

302  {
303  parent::operator=(a_from);
304  return *this;
305  }

◆ store_cls()

virtual const std::string& tools::wroot::leaf_element::store_cls ( ) const
inlinevirtual

Implements tools::wroot::ibo.

Definition at line 276 of file leaf.

276 {return leaf_element_store_class();}

◆ stream()

virtual bool tools::wroot::leaf_element::stream ( buffer a_buffer) const
inlinevirtual

Reimplemented from tools::wroot::base_leaf.

Definition at line 277 of file leaf.

277  {
278  unsigned int c;
279  if(!a_buffer.write_version(1,c)) return false;
280  if(!parent::stream(a_buffer)) return false;
281 
282  if(!a_buffer.write(fID)) return false;
283  if(!a_buffer.write(fType)) return false;
284 
285  if(!a_buffer.set_byte_count(c)) return false;
286  return true;
287  }

Member Data Documentation

◆ fID

int tools::wroot::leaf_element::fID
protected

Definition at line 307 of file leaf.

◆ fType

int tools::wroot::leaf_element::fType
protected

Definition at line 308 of file leaf.


The documentation for this class was generated from the following file:
tools::wroot::leaf_element::id_class
static cid id_class()
Definition: leaf:269
tools::wroot::leaf_element::fType
int fType
Definition: leaf:308
tools::wroot::leaf_element_store_class
const std::string & leaf_element_store_class()
Definition: leaf:39
tools::wroot::leaf_element::fID
int fID
Definition: leaf:307
tools::wroot::base_leaf::cast
virtual void * cast(cid a_class) const
Definition: base_leaf:30
tools::wroot::leaf_element_cid
cid leaf_element_cid()
Definition: cids:17
tools::wroot::base_leaf::operator=
base_leaf & operator=(const base_leaf &)
Definition: base_leaf:92
tools::wroot::base_leaf::m_out
std::ostream & m_out
Definition: base_leaf:101
tools::wroot::base_leaf::stream
virtual bool stream(buffer &a_buffer) const
Definition: base_leaf:36