Ejemplo n.º 1
0
void Initializator::createTypesNodes()
{
    spCreatorNode simple       (new CreatorNode());
    spCreatorNode account      (new TypeAccount());
    spCreatorNode language     (new TypeLanguage());
    spCreatorNode partOfSpeech (new TypePartOfSpeech());
    spCreatorNode dct          (new TypeDct());
    spCreatorNode llForDctLK   (new TypeLLForDctLK());
    spCreatorNode word         (new TypeWord());

    idtnRoot_           = base_->registerTypeNode(simple);
    idtnAccounts_       = base_->registerTypeNode(simple);
    idtnLanguages_      = base_->registerTypeNode(simple);
    idtnParts_OfSpeech_ = base_->registerTypeNode(simple);
    idtnRefLK_          = base_->registerTypeNode(simple);
    idtnRefLL_          = base_->registerTypeNode(simple);
    idtnRefPS_          = base_->registerTypeNode(simple);

    idtnAccount_        = base_->registerTypeNode(account);
    idtnLanguage_       = base_->registerTypeNode(language);
    idtnPart_OfSpeech_  = base_->registerTypeNode(partOfSpeech);
    idtnDct_            = base_->registerTypeNode(dct);
    idtnLLForDctLK_     = base_->registerTypeNode(llForDctLK);
    idtnWord_           = base_->registerTypeNode(word);
}
Ejemplo n.º 2
0
/**
 * @brief
 *  Returns a QStringList of all the word's data linked together
 * @param[in] fileOutput
 *  When set to true (the default value) this will output the part of speech as
 *  a single character instead of a human-understandable word. Set this value
 *  to false when using data() for a human display.
 * @see partOfSpeech
 */
QStringList LyWord::data(bool fileOutput) const
{
    QStringList ret;
    ret << _word;
    if (fileOutput)
        ret << _pos;
    else
        ret << partOfSpeech();
    ret << _definition;
    return ret;
}