LIMA
Libre Multilingual Analyzer — C++ API
Loading...
Searching...
No Matches
Lima::Common::BagOfWords::BoWComplexTokenPrivate Class Reference

#include <linguisticProcessing/common/BagOfWords/bowComplexTokenPrivate.h>

Inheritance diagram for Lima::Common::BagOfWords::BoWComplexTokenPrivate:
Lima::Common::BagOfWords::BoWTokenPrivate Lima::Common::BagOfWords::BoWNamedEntityPrivate Lima::Common::BagOfWords::BoWTermPrivate

Public Member Functions

 BoWComplexTokenPrivate ()
 
 BoWComplexTokenPrivate (const BoWComplexToken &)
 copy constructor
 
 BoWComplexTokenPrivate (const Lima::LimaString &lemma, const LinguisticCode category, const uint64_t position, const uint64_t length)
 
 BoWComplexTokenPrivate (const Lima::LimaString &lemma, const LinguisticCode category, const uint64_t position, const uint64_t length, std::deque< boost::shared_ptr< BoWToken > > &parts, const uint64_t head)
 a constructor to build a simple, independent complex token (parts are simple tokens, not listed elsewhere in a BoWText)
 
virtual ~BoWComplexTokenPrivate ()
 
 BoWComplexTokenPrivate (const BoWComplexTokenPrivate &)
 
BoWComplexTokenPrivate & operator= (const BoWComplexTokenPrivate &)
 
boost::shared_ptr< BoWToken > addPart (boost::shared_ptr< BoWRelation > rel, boost::shared_ptr< BoWToken > tok, const bool isHead=false)
 
void copy (const BoWComplexToken &a)
 
- Public Member Functions inherited from Lima::Common::BagOfWords::BoWTokenPrivate
 BoWTokenPrivate (const Lima::LimaString &lemma, const LinguisticCode category, const uint64_t position, const uint64_t length)
 
 BoWTokenPrivate (const Lima::LimaString &str, const uint64_t position=0, const uint64_t length=0)
 
 BoWTokenPrivate (const BoWToken &tok)
 
 BoWTokenPrivate ()
 
 BoWTokenPrivate (const BoWTokenPrivate &tok)
 
BoWTokenPrivate & operator= (const BoWTokenPrivate &tok)
 
bool operator== (const BoWTokenPrivate &tok)
 
virtual ~BoWTokenPrivate ()
 
void convertSpaces (void)
 convert the spaces in the lemma string into a non-space character (defined by the m_compoundSeparator member)
 

Public Attributes

std::deque< BoWComplexToken::Part > m_parts
 the list of the parts of the complex token
 
uint64_t m_head
 the index of the head of the complex token in its part list
 
- Public Attributes inherited from Lima::Common::BagOfWords::BoWTokenPrivate
Lima::LimaString m_lemma
 
Lima::LimaString m_inflectedForm
 
LinguisticCode m_category
 
uint64_t m_position
 
uint64_t m_length
 
uint64_t m_vertex
 

Friends

class BoWComplexToken
 

Additional Inherited Members

- Static Public Attributes inherited from Lima::Common::BagOfWords::BoWTokenPrivate
static LimaChar m_separator =DEFAULT_SEPARATOR
 
static LimaChar m_compoundSeparator =DEFAULT_COMPOUND_SEPARATOR
 
static bool m_useOnlyLemma =true
 

Detailed Description

Definition at line 33 of file bowComplexTokenPrivate.h.

Constructor & Destructor Documentation

◆ BoWComplexTokenPrivate() [1/5]

Lima::Common::BagOfWords::BoWComplexTokenPrivate::BoWComplexTokenPrivate ( )

Definition at line 30 of file bowComplexToken.cpp.

◆ BoWComplexTokenPrivate() [2/5]

Lima::Common::BagOfWords::BoWComplexTokenPrivate::BoWComplexTokenPrivate ( const BoWComplexToken &  t)

copy constructor

Attention
the copy of the parts of a complex token is tricky : if a part of a complex token points to a token that have a proper existence outside of the part list, the pointer will be copied (no creation of a new object), otherwise a new object is created.

Definition at line 79 of file bowComplexToken.cpp.

◆ BoWComplexTokenPrivate() [3/5]

Lima::Common::BagOfWords::BoWComplexTokenPrivate::BoWComplexTokenPrivate ( const Lima::LimaString &  lemma,
const LinguisticCode  category,
const uint64_t  position,
const uint64_t  length 
)

◆ BoWComplexTokenPrivate() [4/5]

Lima::Common::BagOfWords::BoWComplexTokenPrivate::BoWComplexTokenPrivate ( const Lima::LimaString &  lemma,
const LinguisticCode  category,
const uint64_t  position,
const uint64_t  length,
std::deque< boost::shared_ptr< BoWToken > > &  parts,
const uint64_t  head 
)

a constructor to build a simple, independent complex token (parts are simple tokens, not listed elsewhere in a BoWText)

Parameters
lemmathe lemma of the complex token
categorythe category of the complex token
positionthe position of the complex token
lengththe length of the complex token
partsa deque containing the simple tokens forming the parts of the complex token
inthead the index of the head token in the preceding list
Returns

◆ ~BoWComplexTokenPrivate()

Lima::Common::BagOfWords::BoWComplexTokenPrivate::~BoWComplexTokenPrivate ( )
virtual

Definition at line 88 of file bowComplexToken.cpp.

◆ BoWComplexTokenPrivate() [5/5]

Lima::Common::BagOfWords::BoWComplexTokenPrivate::BoWComplexTokenPrivate ( const BoWComplexTokenPrivate &  bctp)

Definition at line 37 of file bowComplexToken.cpp.

Member Function Documentation

◆ addPart()

boost::shared_ptr< BoWToken > Lima::Common::BagOfWords::BoWComplexTokenPrivate::addPart ( boost::shared_ptr< BoWRelation >  rel,
boost::shared_ptr< BoWToken >  tok,
const bool  isHead = false 
)

Definition at line 219 of file bowComplexToken.cpp.

◆ copy()

void Lima::Common::BagOfWords::BoWComplexTokenPrivate::copy ( const BoWComplexToken &  a)

Definition at line 165 of file bowComplexToken.cpp.

◆ operator=()

BoWComplexTokenPrivate & Lima::Common::BagOfWords::BoWComplexTokenPrivate::operator= ( const BoWComplexTokenPrivate &  )

Friends And Related Symbol Documentation

◆ BoWComplexToken

friend class BoWComplexToken
friend

Definition at line 35 of file bowComplexTokenPrivate.h.

Member Data Documentation

◆ m_head

uint64_t Lima::Common::BagOfWords::BoWComplexTokenPrivate::m_head

the index of the head of the complex token in its part list

Definition at line 81 of file bowComplexTokenPrivate.h.

◆ m_parts

std::deque<BoWComplexToken::Part> Lima::Common::BagOfWords::BoWComplexTokenPrivate::m_parts

the list of the parts of the complex token

Definition at line 79 of file bowComplexTokenPrivate.h.


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