NCBI C++ ToolKit
Public Member Functions | Public Attributes | Private Types | Private Member Functions | List of all members

Search Toolkit Book for CItem

CItem –. More...

#include <build-system/project_tree_builder/msbuild/Item.hpp>

+ Inheritance diagram for CItem:
+ Collaboration diagram for CItem:

Public Member Functions

 CItem (void)
 
virtual ~CItem ()
 
bool apply (const CSeq_entry_Handle &tse, ICommandProccessor *cmdProcessor, const string &title)
 
virtual void apply_to (const CSeq_entry_Handle &tse, CRef< CCmdComposite > composite)=0
 
 CItem (void)
 
 ~CItem (void)
 
 CItem (const Tdata &value)
 Constructor from the primitive type. More...
 
CItemoperator= (const Tdata &value)
 Assignment operator. More...
 
 CItem (void)
 
 ~CItem (void)
 
const stringGetName (void) const
 Get item name from the attributes or empty string. More...
 
const stringGetValue (void) const
 Get string value of the item. More...
 
const stringFindValue (const string &key) const
 If the item has sub-items, return string value for the key or empty string if the key does not exist in the sub-items. More...
 
const CItemFindItem (const string &key) const
 If the item has sub-items, return sub-item for the key or NULL if the key does not exist in the sub-items. More...
 
- Public Member Functions inherited from CItem_Base
 CItem_Base (void)
 
 DECLARE_INTERNAL_TYPE_INFO ()
 
bool IsSetItem (void) const
 
bool CanGetItem (void) const
 
void ResetItem (void)
 
void SetItem (void)
 
 CItem_Base (void)
 
virtual ~CItem_Base (void)
 
 DECLARE_INTERNAL_TYPE_INFO ()
 
 CItem_Base (const Tdata &value)
 Constructor from the primitive type. More...
 
void operator= (const Tdata &value)
 Assignment operator. More...
 
bool IsSet (void) const
 Check if a value has been assigned to data member. More...
 
bool CanGet (void) const
 Check if it is safe to call Get method. More...
 
void Reset (void)
 Reset data member. More...
 
const TdataGet (void) const
 Get the member data. More...
 
void Set (const Tdata &value)
 Assign a value to data member. More...
 
void Set (Tdata &&value)
 
TdataSet (void)
 Assign a value to data member. More...
 
 operator const Tdata & (void) const
 Conversion operator to 'const Tdata' type. More...
 
 operator Tdata & (void)
 Conversion operator to 'Tdata' type. More...
 
 CItem_Base (void)
 
virtual ~CItem_Base (void)
 
 DECLARE_INTERNAL_TYPE_INFO ()
 
bool IsSetAttlist (void) const
 Check if a value has been assigned to Attlist data member. More...
 
bool CanGetAttlist (void) const
 Check if it is safe to call GetAttlist method. More...
 
void ResetAttlist (void)
 Reset Attlist data member. More...
 
const TAttlistGetAttlist (void) const
 Get the Attlist member data. More...
 
void SetAttlist (TAttlist &value)
 Assign a value to Attlist data member. More...
 
TAttlistSetAttlist (void)
 Assign a value to Attlist data member. More...
 
bool IsSetItem (void) const
 Check if a value has been assigned to Item data member. More...
 
bool CanGetItem (void) const
 Check if it is safe to call GetItem method. More...
 
void ResetItem (void)
 Reset Item data member. More...
 
const TItemGetItem (void) const
 Get the Item member data. More...
 
TItemSetItem (void)
 Assign a value to Item data member. More...
 
virtual void Reset (void)
 Reset the whole object. More...
 
- Public Member Functions inherited from CSimpleItemType
 CSimpleItemType (void)
 
 ~CSimpleItemType (void)
 
- Public Member Functions inherited from CSimpleItemType_Base
 CSimpleItemType_Base (void)
 
virtual ~CSimpleItemType_Base (void)
 
 DECLARE_INTERNAL_TYPE_INFO ()
 
bool IsSetAttlist (void) const
 Check if a value has been assigned to Attlist data member. More...
 
bool CanGetAttlist (void) const
 Check if it is safe to call GetAttlist method. More...
 
void ResetAttlist (void)
 Reset Attlist data member. More...
 
const TAttlistGetAttlist (void) const
 Get the Attlist member data. More...
 
void SetAttlist (TAttlist &value)
 Assign a value to Attlist data member. More...
 
TAttlistSetAttlist (void)
 Assign a value to Attlist data member. More...
 
bool IsSetSimpleItemType (void) const
 Check if a value has been assigned to SimpleItemType data member. More...
 
bool CanGetSimpleItemType (void) const
 Check if value of SimpleItemType member is getatable. More...
 
void ResetSimpleItemType (void)
 Reset SimpleItemType data member. More...
 
void SetSimpleItemType (void)
 Set NULL data member (assign 'NULL' value to SimpleItemType data member). More...
 
- Public Member Functions inherited from CObject
 CObject (void)
 Constructor. More...
 
 CObject (const CObject &src)
 Copy constructor. More...
 
virtual ~CObject (void)
 Destructor. More...
 
CObjectoperator= (const CObject &src) THROWS_NONE
 Assignment operator. More...
 
bool CanBeDeleted (void) const THROWS_NONE
 Check if object can be deleted. More...
 
bool IsAllocatedInPool (void) const THROWS_NONE
 Check if object is allocated in memory pool (not system heap) More...
 
bool Referenced (void) const THROWS_NONE
 Check if object is referenced. More...
 
bool ReferencedOnlyOnce (void) const THROWS_NONE
 Check if object is referenced only once. More...
 
void AddReference (void) const
 Add reference to object. More...
 
void RemoveReference (void) const
 Remove reference to object. More...
 
void ReleaseReference (void) const
 Remove reference without deleting object. More...
 
virtual void DoNotDeleteThisObject (void)
 Mark this object as not allocated in heap – do not delete this object. More...
 
virtual void DoDeleteThisObject (void)
 Mark this object as allocated in heap – object can be deleted. More...
 
void * operator new (size_t size)
 Define new operator for memory allocation. More...
 
void * operator new[] (size_t size)
 Define new[] operator for 'array' memory allocation. More...
 
void operator delete (void *ptr)
 Define delete operator for memory deallocation. More...
 
void operator delete[] (void *ptr)
 Define delete[] operator for memory deallocation. More...
 
void * operator new (size_t size, void *place)
 Define new operator. More...
 
void operator delete (void *ptr, void *place)
 Define delete operator. More...
 
void * operator new (size_t size, CObjectMemoryPool *place)
 Define new operator using memory pool. More...
 
void operator delete (void *ptr, CObjectMemoryPool *place)
 Define delete operator. More...
 
virtual void DebugDump (CDebugDumpContext ddc, unsigned int depth) const
 Define method for dumping debug information. More...
 
- Public Member Functions inherited from CDebugDumpable
 CDebugDumpable (void)
 
virtual ~CDebugDumpable (void)
 
void DebugDumpText (ostream &out, const string &bundle, unsigned int depth) const
 
void DebugDumpFormat (CDebugDumpFormatter &ddf, const string &bundle, unsigned int depth) const
 
void DumpToConsole (void) const
 

Public Attributes

TConstScopedObjectsm_SelObjs
 

Private Types

typedef CItem_Base Tparent
 
typedef CItem_Base Tparent
 
typedef CItem_Base Tparent
 

Private Member Functions

 CItem (const CItem &value)
 
CItemoperator= (const CItem &value)
 
 CItem (const CItem &value)
 
CItemoperator= (const CItem &value)
 

Additional Inherited Members

- Public Types inherited from CItem_Base
enum class  E_memberIndex { e__allMandatory = 0 , e_Attlist , e_Item }
 
typedef NCBI_NS_STD::string Tdata
 
typedef C_Attlist TAttlist
 
typedef C_E_Item C_E
 
typedef NCBI_NS_STD::list< NCBI_NS_NCBI::CRef< C_E_Item > > TItem
 
typedef Tparent::CMemberIndex< E_memberIndex, 3 > TmemberIndex
 
- Public Types inherited from CSimpleItemType_Base
enum class  E_memberIndex { e__allMandatory = 0 , e_Attlist , e_SimpleItemType }
 
typedef C_Attlist TAttlist
 
typedef Tparent::CMemberIndex< E_memberIndex, 3 > TmemberIndex
 
- Public Types inherited from CObject
enum  EAllocFillMode { eAllocFillNone = 1 , eAllocFillZero , eAllocFillPattern }
 Control filling of newly allocated memory. More...
 
typedef CObjectCounterLocker TLockerType
 Default locker type for CRef. More...
 
typedef atomic< Uint8TCounter
 Counter type is CAtomiCounter. More...
 
typedef Uint8 TCount
 Alias for value type of counter. More...
 
- Static Public Member Functions inherited from CObject
static NCBI_XNCBI_EXPORT void ThrowNullPointerException (void)
 Define method to throw null pointer exception. More...
 
static NCBI_XNCBI_EXPORT void ThrowNullPointerException (const type_info &type)
 
static EAllocFillMode GetAllocFillMode (void)
 
static void SetAllocFillMode (EAllocFillMode mode)
 
static void SetAllocFillMode (const string &value)
 Set mode from configuration parameter value. More...
 
- Static Public Member Functions inherited from CDebugDumpable
static void EnableDebugDump (bool on)
 
- Static Public Attributes inherited from CObject
static const TCount eCounterBitsCanBeDeleted = 1 << 0
 Define possible object states. More...
 
static const TCount eCounterBitsInPlainHeap = 1 << 1
 Heap signature was found. More...
 
static const TCount eCounterBitsPlaceMask
 Mask for 'in heap' state flags. More...
 
static const int eCounterStep = 1 << 2
 Skip over the "in heap" bits. More...
 
static const TCount eCounterValid = TCount(1) << (sizeof(TCount) * 8 - 2)
 Minimal value for valid objects (reference counter is zero) Must be a single bit value. More...
 
static const TCount eCounterStateMask
 Valid object, and object in heap. More...
 
- Protected Member Functions inherited from CObject
virtual void DeleteThis (void)
 Virtual method "deleting" this object. More...
 

Detailed Description

CItem –.

Definition at line 63 of file Item.hpp.

Member Typedef Documentation

◆ Tparent

typedef CItem_Base CItem::Tparent
private

Definition at line 55 of file Item.hpp.

Constructor & Destructor Documentation

◆ ~CItem() [1/2]

BEGIN_esummary_SCOPE CItem::~CItem ( void  )
inlinevirtual

Definition at line 55 of file citem_util.hpp.

◆ CItem() [1/2]

CItem::CItem ( void  )

◆ ~CItem() [2/2]

CItem::~CItem ( void  )

◆ CItem() [2/2]

CItem::CItem ( const CItem value)
private

Member Function Documentation

◆ apply()

bool CItem::apply ( const CSeq_entry_Handle tse,
ICommandProccessor cmdProcessor,
const string title 
)

◆ apply_to()

virtual void CItem::apply_to ( const CSeq_entry_Handle tse,
CRef< CCmdComposite composite 
)
pure virtual

◆ FindItem()

const CItem * CItem::FindItem ( const string key) const

If the item has sub-items, return sub-item for the key or NULL if the key does not exist in the sub-items.

If there are multiple items for the key, only the first one is returned.

Definition at line 78 of file Item.cpp.

References CItem_Base::C_E_Item::GetItem(), CItem_Base::GetItem(), GetName(), CItem_Base::C_E_Item::IsItem(), ITERATE, ncbi::grid::netcache::search::fields::key, and NULL.

◆ FindValue()

const string & CItem::FindValue ( const string key) const

If the item has sub-items, return string value for the key or empty string if the key does not exist in the sub-items.

If the sub-item contains multiple strings for the key, only the first one is returned.

Definition at line 65 of file Item.cpp.

References CItem_Base::C_E_Item::GetItem(), CItem_Base::GetItem(), GetName(), GetValue(), CItem_Base::C_E_Item::IsItem(), ITERATE, kEmptyStr, and ncbi::grid::netcache::search::fields::key.

◆ GetName()

const string & CItem::GetName ( void  ) const
inline

Get item name from the attributes or empty string.

Definition at line 96 of file Item.hpp.

References CItem_Base::GetAttlist().

Referenced by CDocSum::FindItem(), FindItem(), CDocSum::FindValue(), and FindValue().

◆ GetValue()

const string & CItem::GetValue ( void  ) const

Get string value of the item.

Returns the first _CharData from the sub-items or null if there are no sub-items of type _CharData.

Definition at line 53 of file Item.cpp.

References CItem_Base::C_E_Item::Get_CharData(), CItem_Base::GetItem(), CItem_Base::C_E_Item::Is_CharData(), ITERATE, and kEmptyStr.

Referenced by CDocSum::FindValue(), and FindValue().

◆ operator=()

CItem& CItem::operator= ( const CItem value)
private

Member Data Documentation

◆ m_SelObjs

TConstScopedObjects* CItem::m_SelObjs

Definition at line 61 of file citem_util.hpp.


The documentation for this class was generated from the following files:
Modified on Sat Dec 09 04:48:55 2023 by modify_doxy.py rev. 669887