当前位置: 首页>>代码示例>>C++>>正文


C++ JsonObject::GetValue方法代码示例

本文整理汇总了C++中JsonObject::GetValue方法的典型用法代码示例。如果您正苦于以下问题:C++ JsonObject::GetValue方法的具体用法?C++ JsonObject::GetValue怎么用?C++ JsonObject::GetValue使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在JsonObject的用法示例。


在下文中一共展示了JsonObject::GetValue方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: JsonString

void
SamiAlgorithm::fromJsonObject(IJsonValue* pJson) {
    JsonObject* pJsonObject = static_cast< JsonObject* >(pJson);

    if(pJsonObject != null) {
        JsonString* pProblem_typeKey = new JsonString(L"problem_type");
        IJsonValue* pProblem_typeVal = null;
        pJsonObject->GetValue(pProblem_typeKey, pProblem_typeVal);
        if(pProblem_typeVal != null) {
            
            pProblem_type = new String();
            jsonToValue(pProblem_type, pProblem_typeVal, L"String", L"String");
        }
        delete pProblem_typeKey;
JsonString* pObjectiveKey = new JsonString(L"objective");
        IJsonValue* pObjectiveVal = null;
        pJsonObject->GetValue(pObjectiveKey, pObjectiveVal);
        if(pObjectiveVal != null) {
            
            pObjective = new String();
            jsonToValue(pObjective, pObjectiveVal, L"String", L"String");
        }
        delete pObjectiveKey;
    }
}
开发者ID:graphhopper,项目名称:directions-api-clients-route-optimization,代码行数:25,代码来源:SamiAlgorithm.cpp

示例2: JsonString

void
SamiNAThermMeasure::fromJsonObject(IJsonValue* pJson) {
    JsonObject* pJsonObject = static_cast< JsonObject* >(pJson);

    if(pJsonObject != null) {
        JsonString* pTimeKey = new JsonString(L"time");
        IJsonValue* pTimeVal = null;
        pJsonObject->GetValue(pTimeKey, pTimeVal);
        if(pTimeVal != null) {
            
            pTime = new Integer();
            jsonToValue(pTime, pTimeVal, L"Integer", L"Integer");
        }
        delete pTimeKey;
        JsonString* pTemperatureKey = new JsonString(L"temperature");
        IJsonValue* pTemperatureVal = null;
        pJsonObject->GetValue(pTemperatureKey, pTemperatureVal);
        if(pTemperatureVal != null) {
            
            pTemperature = new Float();
            jsonToValue(pTemperature, pTemperatureVal, L"Float", L"Float");
        }
        delete pTemperatureKey;
        JsonString* pSetpoint_tempKey = new JsonString(L"setpoint_temp");
        IJsonValue* pSetpoint_tempVal = null;
        pJsonObject->GetValue(pSetpoint_tempKey, pSetpoint_tempVal);
        if(pSetpoint_tempVal != null) {
            
            pSetpoint_temp = new Float();
            jsonToValue(pSetpoint_temp, pSetpoint_tempVal, L"Float", L"Float");
        }
        delete pSetpoint_tempKey;
        
    }
}
开发者ID:clinique,项目名称:netatmo-swagger-api,代码行数:35,代码来源:SamiNAThermMeasure.cpp

示例3: JsonString

void
SamiApiResponse::fromJsonObject(IJsonValue* pJson) {
    JsonObject* pJsonObject = static_cast< JsonObject* >(pJson);

    if(pJsonObject != null) {
        JsonString* pCodeKey = new JsonString(L"code");
        IJsonValue* pCodeVal = null;
        pJsonObject->GetValue(pCodeKey, pCodeVal);
        if(pCodeVal != null) {
            
            pCode = new Integer();
            jsonToValue(pCode, pCodeVal, L"Integer", L"Integer");
        }
        delete pCodeKey;
JsonString* pTypeKey = new JsonString(L"type");
        IJsonValue* pTypeVal = null;
        pJsonObject->GetValue(pTypeKey, pTypeVal);
        if(pTypeVal != null) {
            
            pType = new String();
            jsonToValue(pType, pTypeVal, L"String", L"String");
        }
        delete pTypeKey;
JsonString* pMessageKey = new JsonString(L"message");
        IJsonValue* pMessageVal = null;
        pJsonObject->GetValue(pMessageKey, pMessageVal);
        if(pMessageVal != null) {
            
            pMessage = new String();
            jsonToValue(pMessage, pMessageVal, L"String", L"String");
        }
        delete pMessageKey;
    }
}
开发者ID:3dsorcery,项目名称:swagger-codegen,代码行数:34,代码来源:SamiApiResponse.cpp

示例4: JsonString

void
SamiPasswordChangeBody::fromJsonObject(IJsonValue* pJson) {
    JsonObject* pJsonObject = static_cast< JsonObject* >(pJson);

    if(pJsonObject != null) {
        JsonString* pOldPasswordKey = new JsonString(L"oldPassword");
        IJsonValue* pOldPasswordVal = null;
        pJsonObject->GetValue(pOldPasswordKey, pOldPasswordVal);
        if(pOldPasswordVal != null) {
            
            pOldPassword = new String();
            jsonToValue(pOldPassword, pOldPasswordVal, L"String", L"String");
        }
        delete pOldPasswordKey;
        JsonString* pNewPasswordKey = new JsonString(L"newPassword");
        IJsonValue* pNewPasswordVal = null;
        pJsonObject->GetValue(pNewPasswordKey, pNewPasswordVal);
        if(pNewPasswordVal != null) {
            
            pNewPassword = new String();
            jsonToValue(pNewPassword, pNewPasswordVal, L"String", L"String");
        }
        delete pNewPasswordKey;
        JsonString* pKeyKey = new JsonString(L"key");
        IJsonValue* pKeyVal = null;
        pJsonObject->GetValue(pKeyKey, pKeyVal);
        if(pKeyVal != null) {
            
            pKey = new String();
            jsonToValue(pKey, pKeyVal, L"String", L"String");
        }
        delete pKeyKey;
        
    }
}
开发者ID:CloudBoost,项目名称:swagger,代码行数:35,代码来源:SamiPasswordChangeBody.cpp

示例5: JsonString

void
SamiNATimeTableItem::fromJsonObject(IJsonValue* pJson) {
    JsonObject* pJsonObject = static_cast< JsonObject* >(pJson);

    if(pJsonObject != null) {
        JsonString* pIdKey = new JsonString(L"id");
        IJsonValue* pIdVal = null;
        pJsonObject->GetValue(pIdKey, pIdVal);
        if(pIdVal != null) {

            pId = new Integer();
            jsonToValue(pId, pIdVal, L"Integer", L"Integer");
        }
        delete pIdKey;
        JsonString* pM_offsetKey = new JsonString(L"m_offset");
        IJsonValue* pM_offsetVal = null;
        pJsonObject->GetValue(pM_offsetKey, pM_offsetVal);
        if(pM_offsetVal != null) {

            pM_offset = new Integer();
            jsonToValue(pM_offset, pM_offsetVal, L"Integer", L"Integer");
        }
        delete pM_offsetKey;

    }
}
开发者ID:wep4you,项目名称:netatmo-swagger-api,代码行数:26,代码来源:SamiNATimeTableItem.cpp

示例6: JsonString

void
SamiMeasurementValue::fromJsonObject(IJsonValue* pJson) {
    JsonObject* pJsonObject = static_cast< JsonObject* >(pJson);

    if(pJsonObject != null) {
        JsonString* pStart_timeKey = new JsonString(L"start_time");
        IJsonValue* pStart_timeVal = null;
        pJsonObject->GetValue(pStart_timeKey, pStart_timeVal);
        if(pStart_timeVal != null) {
            
            pStart_time = new Long();
            jsonToValue(pStart_time, pStart_timeVal, L"Long", L"Long");
        }
        delete pStart_timeKey;
        JsonString* pValueKey = new JsonString(L"value");
        IJsonValue* pValueVal = null;
        pJsonObject->GetValue(pValueKey, pValueVal);
        if(pValueVal != null) {
            
            pValue = new Float();
            jsonToValue(pValue, pValueVal, L"Float", L"Float");
        }
        delete pValueKey;
        
    }
}
开发者ID:QuantiModo,项目名称:quantimodo-sdk-tizen,代码行数:26,代码来源:SamiMeasurementValue.cpp

示例7: JsonString

void
SamiStatus::fromJsonObject(IJsonValue* pJson) {
    JsonObject* pJsonObject = static_cast< JsonObject* >(pJson);

    if(pJsonObject != null) {
        JsonString* pCodeKey = new JsonString(L"code");
        IJsonValue* pCodeVal = null;
        pJsonObject->GetValue(pCodeKey, pCodeVal);
        if(pCodeVal != null) {
            
            pCode = new String();
            jsonToValue(pCode, pCodeVal, L"String", L"String");
        }
        delete pCodeKey;
        JsonString* pInfoKey = new JsonString(L"info");
        IJsonValue* pInfoVal = null;
        pJsonObject->GetValue(pInfoKey, pInfoVal);
        if(pInfoVal != null) {
            
            pInfo = new String();
            jsonToValue(pInfo, pInfoVal, L"String", L"String");
        }
        delete pInfoKey;
        
    }
}
开发者ID:onlineconvert,项目名称:onlineconvert-api-sdk-tizen,代码行数:26,代码来源:SamiStatus.cpp

示例8: JsonString

void
SamiInline_response_200_28::fromJsonObject(IJsonValue* pJson) {
    JsonObject* pJsonObject = static_cast< JsonObject* >(pJson);

    if(pJsonObject != null) {
        JsonString* pDataKey = new JsonString(L"data");
        IJsonValue* pDataVal = null;
        pJsonObject->GetValue(pDataKey, pDataVal);
        if(pDataVal != null) {
            
            pData = new SamiVariable();
            jsonToValue(pData, pDataVal, L"SamiVariable", L"SamiVariable");
        }
        delete pDataKey;
        JsonString* pSuccessKey = new JsonString(L"success");
        IJsonValue* pSuccessVal = null;
        pJsonObject->GetValue(pSuccessKey, pSuccessVal);
        if(pSuccessVal != null) {
            
            pSuccess = new Boolean(false);
            jsonToValue(pSuccess, pSuccessVal, L"Boolean", L"Boolean");
        }
        delete pSuccessKey;
        
    }
}
开发者ID:QuantiModo,项目名称:quantimodo-sdk-tizen,代码行数:26,代码来源:SamiInline_response_200_28.cpp

示例9: JsonString

void
SamiQuery::fromJsonObject(IJsonValue* pJson) {
    JsonObject* pJsonObject = static_cast< JsonObject* >(pJson);

    if(pJsonObject != null) {
        JsonString* pIncludeListKey = new JsonString(L"$includeList");
        IJsonValue* pIncludeListVal = null;
        pJsonObject->GetValue(pIncludeListKey, pIncludeListVal);
        if(pIncludeListVal != null) {
            pIncludeList = new ArrayList();
            
            jsonToValue(pIncludeList, pIncludeListVal, L"IList", L"String");
        }
        delete pIncludeListKey;
        JsonString* pIncludeKey = new JsonString(L"$include");
        IJsonValue* pIncludeVal = null;
        pJsonObject->GetValue(pIncludeKey, pIncludeVal);
        if(pIncludeVal != null) {
            pInclude = new ArrayList();
            
            jsonToValue(pInclude, pIncludeVal, L"IList", L"String");
        }
        delete pIncludeKey;
        
    }
}
开发者ID:CloudBoost,项目名称:swagger,代码行数:26,代码来源:SamiQuery.cpp

示例10: JsonString

void
SamiCategory::fromJsonObject(IJsonValue* pJson) {
    JsonObject* pJsonObject = static_cast< JsonObject* >(pJson);

    if(pJsonObject != null) {
        JsonString* pIdKey = new JsonString(L"id");
        IJsonValue* pIdVal = null;
        pJsonObject->GetValue(pIdKey, pIdVal);
        if(pIdVal != null) {
            
            pId = new Long();
            jsonToValue(pId, pIdVal, L"Long", L"Long");
        }
        delete pIdKey;
        JsonString* pNameKey = new JsonString(L"name");
        IJsonValue* pNameVal = null;
        pJsonObject->GetValue(pNameKey, pNameVal);
        if(pNameVal != null) {
            
            pName = new String();
            jsonToValue(pName, pNameVal, L"String", L"String");
        }
        delete pNameKey;
        
    }
}
开发者ID:0legg,项目名称:swagger-codegen,代码行数:26,代码来源:SamiCategory.cpp

示例11: JsonString

void
SamiQueueBody::fromJsonObject(IJsonValue* pJson) {
    JsonObject* pJsonObject = static_cast< JsonObject* >(pJson);

    if(pJsonObject != null) {
        JsonString* pDocumentKey = new JsonString(L"document");
        IJsonValue* pDocumentVal = null;
        pJsonObject->GetValue(pDocumentKey, pDocumentVal);
        if(pDocumentVal != null) {
            
            pDocument = new SamiQueue();
            jsonToValue(pDocument, pDocumentVal, L"SamiQueue", L"SamiQueue");
        }
        delete pDocumentKey;
        JsonString* pKeyKey = new JsonString(L"key");
        IJsonValue* pKeyVal = null;
        pJsonObject->GetValue(pKeyKey, pKeyVal);
        if(pKeyVal != null) {
            
            pKey = new String();
            jsonToValue(pKey, pKeyVal, L"String", L"String");
        }
        delete pKeyKey;
        
    }
}
开发者ID:CloudBoost,项目名称:swagger,代码行数:26,代码来源:SamiQueueBody.cpp

示例12: JsonString

void
SamiNAMeasureBodyElem::fromJsonObject(IJsonValue* pJson) {
    JsonObject* pJsonObject = static_cast< JsonObject* >(pJson);

    if(pJsonObject != null) {
        JsonString* pBeg_timeKey = new JsonString(L"beg_time");
        IJsonValue* pBeg_timeVal = null;
        pJsonObject->GetValue(pBeg_timeKey, pBeg_timeVal);
        if(pBeg_timeVal != null) {
            
            pBeg_time = new Integer();
            jsonToValue(pBeg_time, pBeg_timeVal, L"Integer", L"Integer");
        }
        delete pBeg_timeKey;
        JsonString* pStep_timeKey = new JsonString(L"step_time");
        IJsonValue* pStep_timeVal = null;
        pJsonObject->GetValue(pStep_timeKey, pStep_timeVal);
        if(pStep_timeVal != null) {
            
            pStep_time = new Integer();
            jsonToValue(pStep_time, pStep_timeVal, L"Integer", L"Integer");
        }
        delete pStep_timeKey;
        JsonString* pValueKey = new JsonString(L"value");
        IJsonValue* pValueVal = null;
        pJsonObject->GetValue(pValueKey, pValueVal);
        if(pValueVal != null) {
            pValue = new ArrayList();
            
            jsonToValue(pValue, pValueVal, L"IList", L"IList");
        }
        delete pValueKey;
        
    }
}
开发者ID:clinique,项目名称:netatmo-swagger-api,代码行数:35,代码来源:SamiNAMeasureBodyElem.cpp

示例13: JsonString

void
SamiAccessToken::fromJsonObject(IJsonValue* pJson) {
    JsonObject* pJsonObject = static_cast< JsonObject* >(pJson);

    if(pJsonObject != null) {
        JsonString* pAccess_tokenKey = new JsonString(L"access_token");
        IJsonValue* pAccess_tokenVal = null;
        pJsonObject->GetValue(pAccess_tokenKey, pAccess_tokenVal);
        if(pAccess_tokenVal != null) {
            
            pAccess_token = new String();
            jsonToValue(pAccess_token, pAccess_tokenVal, L"String", L"String");
        }
        delete pAccess_tokenKey;
        JsonString* pRefresh_tokenKey = new JsonString(L"refresh_token");
        IJsonValue* pRefresh_tokenVal = null;
        pJsonObject->GetValue(pRefresh_tokenKey, pRefresh_tokenVal);
        if(pRefresh_tokenVal != null) {
            
            pRefresh_token = new String();
            jsonToValue(pRefresh_token, pRefresh_tokenVal, L"String", L"String");
        }
        delete pRefresh_tokenKey;
        JsonString* pExpire_inKey = new JsonString(L"expire_in");
        IJsonValue* pExpire_inVal = null;
        pJsonObject->GetValue(pExpire_inKey, pExpire_inVal);
        if(pExpire_inVal != null) {
            
            pExpire_in = new Integer();
            jsonToValue(pExpire_in, pExpire_inVal, L"Integer", L"Integer");
        }
        delete pExpire_inKey;
        JsonString* pExpires_inKey = new JsonString(L"expires_in");
        IJsonValue* pExpires_inVal = null;
        pJsonObject->GetValue(pExpires_inKey, pExpires_inVal);
        if(pExpires_inVal != null) {
            
            pExpires_in = new Integer();
            jsonToValue(pExpires_in, pExpires_inVal, L"Integer", L"Integer");
        }
        delete pExpires_inKey;
        JsonString* pScopeKey = new JsonString(L"scope");
        IJsonValue* pScopeVal = null;
        pJsonObject->GetValue(pScopeKey, pScopeVal);
        if(pScopeVal != null) {
            pScope = new ArrayList();
            
            jsonToValue(pScope, pScopeVal, L"IList", L"String");
        }
        delete pScopeKey;
        
    }
}
开发者ID:clinique,项目名称:netatmo-swagger-api,代码行数:53,代码来源:SamiAccessToken.cpp

示例14: HandleJavaScriptRequestN

void  LocationMapForm::HandleJavaScriptRequestN (Tizen::Web::Json::IJsonValue *pArg)
{
	 AppLog("PathFinder:: HandleJavaScriptRequestN");
	 result r = E_SUCCESS;
	 JsonObject* pJsonObject = static_cast< JsonObject* >(pArg);
	 IJsonValue* pValue = null;
	 JsonString* pJsonStringValue = null;
	 String key(L"data");

	 r = pJsonObject->GetValue(&key, pValue);
	 pJsonStringValue = static_cast< JsonString* >(pValue);
	 const wchar_t* mapPointString = pJsonStringValue->GetPointer();

	 AppLog("data: %ls\n", mapPointString);

	 String *tmpString = new String(mapPointString);

	 Float x , y;

	 int idx = 0;


	 tmpString->IndexOf(' ' , 0 , idx);

	 String *tmpString2 = new String ( mapPointString + idx + 1 );

	 const wchar_t* tmpChar =  tmpString->GetPointer();
	 wchar_t* tmpChar3 = const_cast<wchar_t*>(tmpChar);
	 tmpChar3[idx] = '\0';
	 const wchar_t* tmpChar2 = tmpString2->GetPointer();

	 x.Parse(tmpChar3 , this->__latitude );
	 y.Parse(tmpChar2 , this->__longitude );
}
开发者ID:PassionJHack,项目名称:passion,代码行数:34,代码来源:LocationMapForm.cpp

示例15: JsonString

void
SamiFeatures::fromJsonObject(IJsonValue* pJson) {
    JsonObject* pJsonObject = static_cast< JsonObject* >(pJson);

    if(pJsonObject != null) {
        JsonString* p_idKey = new JsonString(L"_id");
        IJsonValue* p_idVal = null;
        pJsonObject->GetValue(p_idKey, p_idVal);
        if(p_idVal != null) {
            
            p_id = new String();
            jsonToValue(p_id, p_idVal, L"String", L"String");
        }
        delete p_idKey;
        
    }
}
开发者ID:bleepbloopsify,项目名称:Clients,代码行数:17,代码来源:SamiFeatures.cpp


注:本文中的JsonObject::GetValue方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。