Esempio n. 1
0
bool AuthorNode::getValue (const String& strMemberName, String& strValue)
{
    bool bValueSet = false;
    Author* pObject = dynamic_cast<Author*>(m_pObject);
    if (strMemberName == L"value")
    {
        ValueObject* pValueObj = dynamic_cast<ValueObject*>(m_pObject);
        if (pValueObj)
        {
            if (!pValueObj->isNothing())
            {
                strValue = pValueObj->toString();
                bValueSet = true;
            }
        }
    }
    else if (strMemberName == L"CreatedBy")
    {
        if (pObject->hasValue_CreatedBy())
        {
            strValue = (StringObjectImpl(pObject->getCreatedBy())).toString();
            bValueSet = true;
        }
    }
    else if (strMemberName == L"CreatedByEmail")
    {
        if (pObject->hasValue_CreatedByEmail())
        {
            strValue = (StringObjectImpl(pObject->getCreatedByEmail())).toString();
            bValueSet = true;
        }
    }
    else if (strMemberName == L"Company")
    {
        if (pObject->hasValue_Company())
        {
            strValue = (StringObjectImpl(pObject->getCompany())).toString();
            bValueSet = true;
        }
    }
    else if (strMemberName == L"CompanyURL")
    {
        if (pObject->hasValue_CompanyURL())
        {
            strValue = (StringObjectImpl(pObject->getCompanyURL())).toString();
            bValueSet = true;
        }
    }
    else if (strMemberName == L"TimeStamp")
    {
        if (pObject->hasValue_TimeStamp())
        {
            strValue = (StringObjectImpl(pObject->getTimeStamp())).toString();
            bValueSet = true;
        }
    }
    return bValueSet;
}