コード例 #1
0
JsonObject*
SamiNewsletter::asJsonObject() {
    JsonObject *pJsonObject = new JsonObject();
    pJsonObject->Construct();

    
    JsonString *p_idKey = new JsonString(L"_id");
    pJsonObject->Add(p_idKey, toJson(getPId(), "String", ""));

    
    JsonString *pIs_sentKey = new JsonString(L"is_sent");
    pJsonObject->Add(pIs_sentKey, toJson(getPIsSent(), "Boolean", ""));

    
    JsonString *pIs_defaultKey = new JsonString(L"is_default");
    pJsonObject->Add(pIs_defaultKey, toJson(getPIsDefault(), "Boolean", ""));

    
    JsonString *pClick_countKey = new JsonString(L"click_count");
    pJsonObject->Add(pClick_countKey, toJson(getPClickCount(), "Long", ""));

    
    JsonString *pUnique_click_countKey = new JsonString(L"unique_click_count");
    pJsonObject->Add(pUnique_click_countKey, toJson(getPUniqueClickCount(), "Long", ""));

    
    JsonString *pTotal_click_countKey = new JsonString(L"total_click_count");
    pJsonObject->Add(pTotal_click_countKey, toJson(getPTotalClickCount(), "Long", ""));

    
    return pJsonObject;
}
コード例 #2
0
ファイル: SamiPet.cpp プロジェクト: 0legg/swagger-codegen
JsonObject*
SamiPet::asJsonObject() {
    JsonObject *pJsonObject = new JsonObject();
    pJsonObject->Construct();

    
    JsonString *pIdKey = new JsonString(L"id");
    pJsonObject->Add(pIdKey, toJson(getPId(), "Long", ""));

    
    JsonString *pCategoryKey = new JsonString(L"category");
    pJsonObject->Add(pCategoryKey, toJson(getPCategory(), "SamiCategory", ""));

    
    JsonString *pNameKey = new JsonString(L"name");
    pJsonObject->Add(pNameKey, toJson(getPName(), "String", ""));

    
    JsonString *pPhotoUrlsKey = new JsonString(L"photoUrls");
    pJsonObject->Add(pPhotoUrlsKey, toJson(getPPhotoUrls(), "String", "array"));

    
    JsonString *pTagsKey = new JsonString(L"tags");
    pJsonObject->Add(pTagsKey, toJson(getPTags(), "SamiTag", "array"));

    
    JsonString *pStatusKey = new JsonString(L"status");
    pJsonObject->Add(pStatusKey, toJson(getPStatus(), "String", ""));

    
    return pJsonObject;
}
JsonObject*
SamiShipment::asJsonObject() {
    JsonObject *pJsonObject = new JsonObject();
    pJsonObject->Construct();

    JsonString *pIdKey = new JsonString(L"id");
    pJsonObject->Add(pIdKey, toJson(getPId(), "String", ""));

    JsonString *pNameKey = new JsonString(L"name");
    pJsonObject->Add(pNameKey, toJson(getPName(), "String", ""));

    JsonString *pPriorityKey = new JsonString(L"priority");
    pJsonObject->Add(pPriorityKey, toJson(getPPriority(), "Integer", ""));

    JsonString *pPickupKey = new JsonString(L"pickup");
    pJsonObject->Add(pPickupKey, toJson(getPPickup(), "SamiStop", ""));

    JsonString *pDeliveryKey = new JsonString(L"delivery");
    pJsonObject->Add(pDeliveryKey, toJson(getPDelivery(), "SamiStop", ""));

    JsonString *pSizeKey = new JsonString(L"size");
    pJsonObject->Add(pSizeKey, toJson(getPSize(), "Integer", "array"));

    JsonString *pRequired_skillsKey = new JsonString(L"required_skills");
    pJsonObject->Add(pRequired_skillsKey, toJson(getPRequiredSkills(), "String", "array"));

    JsonString *pAllowed_vehiclesKey = new JsonString(L"allowed_vehicles");
    pJsonObject->Add(pAllowed_vehiclesKey, toJson(getPAllowedVehicles(), "String", "array"));

    return pJsonObject;
}
コード例 #4
0
ファイル: SamiEvent.cpp プロジェクト: bleepbloopsify/Clients
JsonObject*
SamiEvent::asJsonObject() {
    JsonObject *pJsonObject = new JsonObject();
    pJsonObject->Construct();

    
    JsonString *p_idKey = new JsonString(L"_id");
    pJsonObject->Add(p_idKey, toJson(getPId(), "String", ""));

    
    JsonString *pTypeKey = new JsonString(L"type");
    pJsonObject->Add(pTypeKey, toJson(getPType(), "String", ""));

    
    JsonString *pRefererKey = new JsonString(L"referer");
    pJsonObject->Add(pRefererKey, toJson(getPReferer(), "String", ""));

    
    JsonString *pOriginal_urlKey = new JsonString(L"original_url");
    pJsonObject->Add(pOriginal_urlKey, toJson(getPOriginalUrl(), "String", ""));

    
    JsonString *pOriginator_emailKey = new JsonString(L"originator_email");
    pJsonObject->Add(pOriginator_emailKey, toJson(getPOriginatorEmail(), "String", ""));

    
    JsonString *pSubject_emailKey = new JsonString(L"subject_email");
    pJsonObject->Add(pSubject_emailKey, toJson(getPSubjectEmail(), "String", ""));

    
    JsonString *pParent_event_idKey = new JsonString(L"parent_event_id");
    pJsonObject->Add(pParent_event_idKey, toJson(getPParentEventId(), "String", ""));

    
    JsonString *pOriginator_idKey = new JsonString(L"originator_id");
    pJsonObject->Add(pOriginator_idKey, toJson(getPOriginatorId(), "String", ""));

    
    JsonString *pAdvisor_idKey = new JsonString(L"advisor_id");
    pJsonObject->Add(pAdvisor_idKey, toJson(getPAdvisorId(), "String", ""));

    
    JsonString *pSubject_idKey = new JsonString(L"subject_id");
    pJsonObject->Add(pSubject_idKey, toJson(getPSubjectId(), "String", ""));

    
    JsonString *pEvent_contentKey = new JsonString(L"event_content");
    pJsonObject->Add(pEvent_contentKey, toJson(getPEventContent(), "SamiEventContent", ""));

    
    JsonString *pCreated_atKey = new JsonString(L"created_at");
    pJsonObject->Add(pCreated_atKey, toJson(getPCreatedAt(), "String", ""));

    
    return pJsonObject;
}
コード例 #5
0
JsonObject*
SamiFeatures::asJsonObject() {
    JsonObject *pJsonObject = new JsonObject();
    pJsonObject->Construct();

    
    JsonString *p_idKey = new JsonString(L"_id");
    pJsonObject->Add(p_idKey, toJson(getPId(), "String", ""));

    
    return pJsonObject;
}
コード例 #6
0
JsonObject*
SamiCategory::asJsonObject() {
    JsonObject *pJsonObject = new JsonObject();
    pJsonObject->Construct();

    
    JsonString *pIdKey = new JsonString(L"id");
    pJsonObject->Add(pIdKey, toJson(getPId(), "Long", ""));

    
    JsonString *pNameKey = new JsonString(L"name");
    pJsonObject->Add(pNameKey, toJson(getPName(), "String", ""));

    
    return pJsonObject;
}
コード例 #7
0
JsonObject*
SamiNATimeTableItem::asJsonObject() {
    JsonObject *pJsonObject = new JsonObject();
    pJsonObject->Construct();


    JsonString *pIdKey = new JsonString(L"id");
    pJsonObject->Add(pIdKey, toJson(getPId(), "Integer", ""));


    JsonString *pM_offsetKey = new JsonString(L"m_offset");
    pJsonObject->Add(pM_offsetKey, toJson(getPMOffset(), "Integer", ""));


    return pJsonObject;
}
コード例 #8
0
ファイル: SamiGroup.cpp プロジェクト: bleepbloopsify/Clients
JsonObject*
SamiGroup::asJsonObject() {
    JsonObject *pJsonObject = new JsonObject();
    pJsonObject->Construct();

    
    JsonString *p_idKey = new JsonString(L"_id");
    pJsonObject->Add(p_idKey, toJson(getPId(), "String", ""));

    
    JsonString *pNameKey = new JsonString(L"name");
    pJsonObject->Add(pNameKey, toJson(getPName(), "String", ""));

    
    JsonString *pIs_defaultKey = new JsonString(L"is_default");
    pJsonObject->Add(pIs_defaultKey, toJson(getPIsDefault(), "Boolean", ""));

    
    JsonString *pIs_hiddenKey = new JsonString(L"is_hidden");
    pJsonObject->Add(pIs_hiddenKey, toJson(getPIsHidden(), "Boolean", ""));

    
    JsonString *pNew_weekly_mailer_contentKey = new JsonString(L"new_weekly_mailer_content");
    pJsonObject->Add(pNew_weekly_mailer_contentKey, toJson(getPNewWeeklyMailerContent(), "String", ""));

    
    JsonString *pNewsletter_subjectKey = new JsonString(L"newsletter_subject");
    pJsonObject->Add(pNewsletter_subjectKey, toJson(getPNewsletterSubject(), "String", ""));

    
    JsonString *pAutopublishKey = new JsonString(L"autopublish");
    pJsonObject->Add(pAutopublishKey, toJson(getPAutopublish(), "Boolean", ""));

    
    JsonString *pNumber_articles_per_groupKey = new JsonString(L"number_articles_per_group");
    pJsonObject->Add(pNumber_articles_per_groupKey, toJson(getPNumberArticlesPerGroup(), "Integer", ""));

    
    JsonString *pNumber_articles_per_newsletterKey = new JsonString(L"number_articles_per_newsletter");
    pJsonObject->Add(pNumber_articles_per_newsletterKey, toJson(getPNumberArticlesPerNewsletter(), "Integer", ""));

    
    return pJsonObject;
}
コード例 #9
0
JsonObject*
SamiShowcaseDatatypePrimitives::asJsonObject() {
    JsonObject *pJsonObject = new JsonObject();
    pJsonObject->Construct();

    
    JsonString *pSingleByteKey = new JsonString(L"singleByte");
    pJsonObject->Add(pSingleByteKey, toJson(getPSingleByte(), "String", ""));

    
    JsonString *pTinyNumberKey = new JsonString(L"tinyNumber");
    pJsonObject->Add(pTinyNumberKey, toJson(getPTinyNumber(), "Integer", ""));

    
    JsonString *pCounterKey = new JsonString(L"counter");
    pJsonObject->Add(pCounterKey, toJson(getPCounter(), "Integer", ""));

    
    JsonString *pIdKey = new JsonString(L"id");
    pJsonObject->Add(pIdKey, toJson(getPId(), "Long", ""));

    
    JsonString *pBudgetFloatKey = new JsonString(L"budgetFloat");
    pJsonObject->Add(pBudgetFloatKey, toJson(getPBudgetFloat(), "Long", ""));

    
    JsonString *pBudgetKey = new JsonString(L"budget");
    pJsonObject->Add(pBudgetKey, toJson(getPBudget(), "Double", ""));

    
    JsonString *pDeletedKey = new JsonString(L"deleted");
    pJsonObject->Add(pDeletedKey, toJson(getPDeleted(), "Boolean", ""));

    
    JsonString *pSingleCharacterKey = new JsonString(L"singleCharacter");
    pJsonObject->Add(pSingleCharacterKey, toJson(getPSingleCharacter(), "String", ""));

    
    return pJsonObject;
}
JsonObject*
SamiActivity::asJsonObject() {
    JsonObject *pJsonObject = new JsonObject();
    pJsonObject->Construct();

    JsonString *pTypeKey = new JsonString(L"type");
    pJsonObject->Add(pTypeKey, toJson(getPType(), "String", ""));

    JsonString *pIdKey = new JsonString(L"id");
    pJsonObject->Add(pIdKey, toJson(getPId(), "String", ""));

    JsonString *pLocation_idKey = new JsonString(L"location_id");
    pJsonObject->Add(pLocation_idKey, toJson(getPLocationId(), "String", ""));

    JsonString *pArr_timeKey = new JsonString(L"arr_time");
    pJsonObject->Add(pArr_timeKey, toJson(getPArrTime(), "Long", ""));

    JsonString *pEnd_timeKey = new JsonString(L"end_time");
    pJsonObject->Add(pEnd_timeKey, toJson(getPEndTime(), "Long", ""));

    JsonString *pWaiting_timeKey = new JsonString(L"waiting_time");
    pJsonObject->Add(pWaiting_timeKey, toJson(getPWaitingTime(), "Long", ""));

    JsonString *pDistanceKey = new JsonString(L"distance");
    pJsonObject->Add(pDistanceKey, toJson(getPDistance(), "Long", ""));

    JsonString *pDriving_timeKey = new JsonString(L"driving_time");
    pJsonObject->Add(pDriving_timeKey, toJson(getPDrivingTime(), "Long", ""));

    JsonString *pLoad_beforeKey = new JsonString(L"load_before");
    pJsonObject->Add(pLoad_beforeKey, toJson(getPLoadBefore(), "Integer", "array"));

    JsonString *pLoad_afterKey = new JsonString(L"load_after");
    pJsonObject->Add(pLoad_afterKey, toJson(getPLoadAfter(), "Integer", "array"));

    return pJsonObject;
}
コード例 #11
0
ファイル: SamiPost.cpp プロジェクト: bleepbloopsify/Clients
JsonObject*
SamiPost::asJsonObject() {
    JsonObject *pJsonObject = new JsonObject();
    pJsonObject->Construct();

    
    JsonString *p_idKey = new JsonString(L"_id");
    pJsonObject->Add(p_idKey, toJson(getPId(), "String", ""));

    
    JsonString *pCreated_atKey = new JsonString(L"created_at");
    pJsonObject->Add(pCreated_atKey, toJson(getPCreatedAt(), "String", ""));

    
    JsonString *pUpdated_atKey = new JsonString(L"updated_at");
    pJsonObject->Add(pUpdated_atKey, toJson(getPUpdatedAt(), "String", ""));

    
    JsonString *pExternal_urlKey = new JsonString(L"external_url");
    pJsonObject->Add(pExternal_urlKey, toJson(getPExternalUrl(), "String", ""));

    
    JsonString *pExternal_url_sourceKey = new JsonString(L"external_url_source");
    pJsonObject->Add(pExternal_url_sourceKey, toJson(getPExternalUrlSource(), "String", ""));

    
    JsonString *pExternal_url_typeKey = new JsonString(L"external_url_type");
    pJsonObject->Add(pExternal_url_typeKey, toJson(getPExternalUrlType(), "String", ""));

    
    JsonString *pImage_pathKey = new JsonString(L"image_path");
    pJsonObject->Add(pImage_pathKey, toJson(getPImagePath(), "String", ""));

    
    JsonString *pImage_urlKey = new JsonString(L"image_url");
    pJsonObject->Add(pImage_urlKey, toJson(getPImageUrl(), "String", ""));

    
    JsonString *pImage_heightKey = new JsonString(L"image_height");
    pJsonObject->Add(pImage_heightKey, toJson(getPImageHeight(), "String", ""));

    
    JsonString *pImage_widthKey = new JsonString(L"image_width");
    pJsonObject->Add(pImage_widthKey, toJson(getPImageWidth(), "String", ""));

    
    JsonString *pLogo_urlKey = new JsonString(L"logo_url");
    pJsonObject->Add(pLogo_urlKey, toJson(getPLogoUrl(), "String", ""));

    
    JsonString *pSquare_logo_urlKey = new JsonString(L"square_logo_url");
    pJsonObject->Add(pSquare_logo_urlKey, toJson(getPSquareLogoUrl(), "String", ""));

    
    JsonString *pNeeds_sanitizeKey = new JsonString(L"needs_sanitize");
    pJsonObject->Add(pNeeds_sanitizeKey, toJson(getPNeedsSanitize(), "String", ""));

    
    JsonString *pSummaryKey = new JsonString(L"summary");
    pJsonObject->Add(pSummaryKey, toJson(getPSummary(), "String", ""));

    
    JsonString *pTopicKey = new JsonString(L"topic");
    pJsonObject->Add(pTopicKey, toJson(getPTopic(), "String", ""));

    
    JsonString *pApproval_statusKey = new JsonString(L"approval_status");
    pJsonObject->Add(pApproval_statusKey, toJson(getPApprovalStatus(), "String", ""));

    
    JsonString *pApproval_transactionsKey = new JsonString(L"approval_transactions");
    pJsonObject->Add(pApproval_transactionsKey, toJson(getPApprovalTransactions(), "String", "array"));

    
    JsonString *pGroup_idsKey = new JsonString(L"group_ids");
    pJsonObject->Add(pGroup_idsKey, toJson(getPGroupIds(), "String", "array"));

    
    JsonString *pSlugKey = new JsonString(L"slug");
    pJsonObject->Add(pSlugKey, toJson(getPSlug(), "String", ""));

    
    JsonString *pArticle_idKey = new JsonString(L"article_id");
    pJsonObject->Add(pArticle_idKey, toJson(getPArticleId(), "String", ""));

    
    JsonString *pCommentKey = new JsonString(L"comment");
    pJsonObject->Add(pCommentKey, toJson(getPComment(), "String", ""));

    
    JsonString *pNewsletter_idsKey = new JsonString(L"newsletter_ids");
    pJsonObject->Add(pNewsletter_idsKey, toJson(getPNewsletterIds(), "String", "array"));

    
    JsonString *pIs_featuredKey = new JsonString(L"is_featured");
    pJsonObject->Add(pIs_featuredKey, toJson(getPIsFeatured(), "Boolean", ""));

    
    JsonString *pAdvisor_idKey = new JsonString(L"advisor_id");
    pJsonObject->Add(pAdvisor_idKey, toJson(getPAdvisorId(), "String", ""));

    
    JsonString *pIs_publishedKey = new JsonString(L"is_published");
    pJsonObject->Add(pIs_publishedKey, toJson(getPIsPublished(), "Boolean", ""));

    
    JsonString *pIs_responsiveKey = new JsonString(L"is_responsive");
    pJsonObject->Add(pIs_responsiveKey, toJson(getPIsResponsive(), "Boolean", ""));

    
    JsonString *pIs_proxy_neededKey = new JsonString(L"is_proxy_needed");
    pJsonObject->Add(pIs_proxy_neededKey, toJson(getPIsProxyNeeded(), "Boolean", ""));

    
    JsonString *pIs_mobile_proxy_neededKey = new JsonString(L"is_mobile_proxy_needed");
    pJsonObject->Add(pIs_mobile_proxy_neededKey, toJson(getPIsMobileProxyNeeded(), "Boolean", ""));

    
    JsonString *pProxy_urlKey = new JsonString(L"proxy_url");
    pJsonObject->Add(pProxy_urlKey, toJson(getPProxyUrl(), "String", ""));

    
    JsonString *pVideoKey = new JsonString(L"video");
    pJsonObject->Add(pVideoKey, toJson(getPVideo(), "String", ""));

    
    JsonString *pPdf_attachment_urlKey = new JsonString(L"pdf_attachment_url");
    pJsonObject->Add(pPdf_attachment_urlKey, toJson(getPPdfAttachmentUrl(), "String", ""));

    
    JsonString *pPost_dateKey = new JsonString(L"post_date");
    pJsonObject->Add(pPost_dateKey, toJson(getPPostDate(), "String", ""));

    
    JsonString *pDisplay_dateKey = new JsonString(L"display_date");
    pJsonObject->Add(pDisplay_dateKey, toJson(getPDisplayDate(), "String", ""));

    
    JsonString *pSuitability_scoreKey = new JsonString(L"suitability_score");
    pJsonObject->Add(pSuitability_scoreKey, toJson(getPSuitabilityScore(), "String", ""));

    
    JsonString *pVideo_idKey = new JsonString(L"video_id");
    pJsonObject->Add(pVideo_idKey, toJson(getPVideoId(), "String", ""));

    
    JsonString *pDisplay_tagKey = new JsonString(L"display_tag");
    pJsonObject->Add(pDisplay_tagKey, toJson(getPDisplayTag(), "String", ""));

    
    JsonString *pDisplay_summaryKey = new JsonString(L"display_summary");
    pJsonObject->Add(pDisplay_summaryKey, toJson(getPDisplaySummary(), "String", ""));

    
    JsonString *pVestorly_urlKey = new JsonString(L"vestorly_url");
    pJsonObject->Add(pVestorly_urlKey, toJson(getPVestorlyUrl(), "String", ""));

    
    JsonString *pTitleKey = new JsonString(L"title");
    pJsonObject->Add(pTitleKey, toJson(getPTitle(), "String", ""));

    
    return pJsonObject;
}