NCBI C++ ToolKit
Public Types | Public Member Functions | Private Types | Private Member Functions | Static Private Member Functions
CPub Class Reference

Represents ASN.1 type Pub defined in file pub.asn

Search Toolkit Book for CPub

#include <objects/pub/Pub.hpp>

+ Inheritance diagram for CPub:
+ Collaboration diagram for CPub:

List of all members.

Public Types

enum  ELabelType { eType, eContent, eBoth }
typedef CConstRef< CTitle::C_ETOneTitleRef
typedef vector< TOneTitleRefTOneTitleRefVec

Public Member Functions

 CPub (void)
 ~CPub (void)
bool GetLabel (string *label, ELabelType type=eContent, TLabelFlags flags=0, ELabelVersion version=eLabel_DefaultVersion) const
 Concatenate a label for this pub to label.
bool GetLabel (string *label, ELabelType type, bool unique=false) const
bool GetLabel (string *label, TLabelFlags flags=0, ELabelVersion version=eLabel_DefaultVersion) const
 Append a label to the specified string per the specified flags.
bool IsSetAuthors (void) const
const CAuth_listGetAuthors (void) const
void GetTitles (TOneTitleRefVec &out_title, size_t iMaxToGet=std::numeric_limits< std::size_t >::max()) const
 This gets the titles on the CPub.

Private Types

typedef CPub_Base Tparent

Private Member Functions

 CPub (const CPub &value)
CPuboperator= (const CPub &value)

Static Private Member Functions

static TOneTitleRef xs_GetTitleFromPlainString (const string &sTitle)
static void xs_AppendTitles (TOneTitleRefVec &out_title, size_t iMaxToGet, const CTitle &in_title)

Detailed Description

Definition at line 55 of file Pub.hpp.

Member Typedef Documentation

Definition at line 88 of file Pub.hpp.

Definition at line 89 of file Pub.hpp.

typedef CPub_Base CPub::Tparent [private]

Reimplemented from CPub_Base.

Definition at line 57 of file Pub.hpp.

Member Enumeration Documentation


Definition at line 64 of file Pub.hpp.

Constructor & Destructor Documentation

CPub::CPub ( void  ) [inline]

Definition at line 127 of file Pub.hpp.

CPub::~CPub ( void  )

Definition at line 65 of file Pub.cpp.

CPub::CPub ( const CPub value) [private]

Member Function Documentation

const CAuth_list & CPub::GetAuthors ( void  ) const
bool CPub::GetLabel ( string label,
ELabelType  type = eContent,
TLabelFlags  flags = 0,
ELabelVersion  version = eLabel_DefaultVersion 
) const
bool CPub::GetLabel ( string label,
ELabelType  type,
bool  unique = false 
) const [inline]

Definition at line 132 of file Pub.hpp.

References IAbstractCitation::fLabel_Unique, and GetLabel().

bool CPub::GetLabel ( string label,
TLabelFlags  flags = 0,
ELabelVersion  version = eLabel_DefaultVersion 
) const [inline, virtual]

Append a label to the specified string per the specified flags.

Implements IAbstractCitation.

Definition at line 138 of file Pub.hpp.

References eContent, and GetLabel().

void CPub::GetTitles ( TOneTitleRefVec out_title,
size_t  iMaxToGet = std::numeric_limits<std::size_t>::max() 
) const

This gets the titles on the CPub.

out_titlesEach title found will be appended to this. Titles of plain strings will be given as type CTitle::C_E::e_Name, and complex titles will be a const reference to the title inside the CPub, so they might change if the CPub is changed.
iMaxToGetThe maximum number of titles to append to out_title

Definition at line 195 of file Pub.cpp.

References CPub_Base::e_Article, CPub_Base::e_Book, CPub_Base::e_Equiv, CPub_Base::e_Gen, CPub_Base::e_Journal, CPub_Base::e_Man, CPub_Base::e_Medline, CPub_Base::e_not_set, CPub_Base::e_Pat_id, CPub_Base::e_Patent, CPub_Base::e_Pmid, CPub_Base::e_Proc, CPub_Base::e_Sub, eUnknown, FIELD_CHAIN_OF_2_IS_SET, FOR_EACH_PUB_ON_PUBEQUIV, CPub_Base::GetArticle(), CPub_Base::GetBook(), CPub_Base::GetEquiv(), CPub_Base::GetGen(), CPub_Base::GetJournal(), CPub_Base::GetMan(), CPub_Base::GetPatent(), CPub_Base::GetProc(), CPub_Base::GetSub(), GetTitle(), max(), NCBI_THROW, CPub_Base::Which(), xs_AppendTitles(), and xs_GetTitleFromPlainString().

bool CPub::IsSetAuthors ( void  ) const
CPub& CPub::operator= ( const CPub value) [private]
void CPub::xs_AppendTitles ( TOneTitleRefVec out_title,
size_t  iMaxToGet,
const CTitle in_title 
) [static, private]

Definition at line 296 of file Pub.cpp.

References CTitle_Base::Get(), and CTitle_Base::IsSet().

Referenced by GetTitles().

Definition at line 288 of file Pub.cpp.

References CTitle_Base::C_E::SetName().

Referenced by GetTitles().

The documentation for this class was generated from the following files:
Modified on Sun Sep 21 18:23:49 2014 by rev. 426318