gatb.core-API-0.0.0
Group Class Reference

Group concept. More...

#include <Storage.hpp>

Inheritance diagram for Group:
Inheritance graph

Public Member Functions

 Group (StorageFactory *factory, ICell *parent, const std::string &name)
 
 ~Group ()
 
GroupgetGroup (const std::string &name)
 
template<class Type >
Partition< Type > & getPartition (const std::string &name, size_t nb=0)
 
template<class Type >
CollectionNode< Type > & getCollection (const std::string &name)
 
void remove ()
 
virtual void addProperty (const std::string &key, const std::string value)
 
virtual std::string getProperty (const std::string &key)
 
- Public Member Functions inherited from Cell
 Cell (ICell *parent, const std::string &id)
 
 ~Cell ()
 
ICellgetParent () const
 
const std::string & getId () const
 
std::string getFullId (char sep='.') const
 
void setCompressLevel (int level)
 
int getCompressLevel () const
 
- Public Member Functions inherited from ICell
virtual ~ICell ()
 
- Public Member Functions inherited from ISmartPointer
virtual ~ISmartPointer ()
 
- Public Member Functions inherited from SmartPointer
void use ()
 
void forget ()
 

Additional Inherited Members

- Static Public Member Functions inherited from ICell
static ICellgetRoot (ICell *cell)
 
- Protected Member Functions inherited from SmartPointer
 SmartPointer ()
 
virtual ~SmartPointer ()
 

Detailed Description

Group concept.

This class define a container concept for other items that can be stored in a storage (like groups, partitions, collections).

In a regular implementation, a Group could be a directory.

In a HDF5 implementation, a group could be a HDF5 group.

Constructor & Destructor Documentation

Group ( StorageFactory factory,
ICell parent,
const std::string &  name 
)

Constructor.

~Group ( )

Destructor.

Member Function Documentation

virtual void addProperty ( const std::string &  key,
const std::string  value 
)
inlinevirtual

Associate a [key,value] to the group. Note: according to the kind of storage, this feature may be not supported (looks like it's only supported in HDF5).

Parameters
[in]key: key
[in]value: value
CollectionNode<Type>& getCollection ( const std::string &  name)

Get a child collection from its name. Created if not already exists.

Parameters
[in]name: name of the child collection to be retrieved.
Returns
the child collection .
Group& getGroup ( const std::string &  name)

Get a child group from its name. Created if not already exists.

Parameters
[in]name: name of the child group to be retrieved.
Returns
the child group.
Partition<Type>& getPartition ( const std::string &  name,
size_t  nb = 0 
)

Get a child partition from its name. Created if not already exists.

Parameters
[in]name: name of the child partition to be retrieved.
[in]nb: in case of creation, tells how many collection belong to the partition.
Returns
the child partition.
virtual std::string getProperty ( const std::string &  key)
inlinevirtual

Get a [key,value] from the group. Note: according to the kind of storage, this feature may be not supported (looks like it's only supported in HDF5).

Parameters
[in]key: key
Returns
the value associated to the string.
void remove ( )
virtual

Physically remove the node.

Implements ICell.

Reimplemented in Partition< Type >, and Partition< gatb::core::kmer::impl::Kmer::Count >.


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