Home | History | Annotate | Download | only in cloud_print
      1 // Copyright 2012 The Chromium Authors. All rights reserved.
      2 // Use of this source code is governed by a BSD-style license that can be
      3 // found in the LICENSE file.
      4 
      5 #include "chrome/common/cloud_print/cloud_print_constants.h"
      6 
      7 namespace cloud_print {
      8 
      9 const char kCloudPrintUserAgent[] = "GoogleCloudPrintProxy";
     10 const char kChromeCloudPrintProxyHeader[] = "X-CloudPrint-Proxy: Chrome";
     11 const char kCloudPrintPushNotificationsSource[] = "cloudprint.google.com";
     12 
     13 const char kProxyIdValue[] = "proxy";
     14 const char kPrinterNameValue[] = "printer";
     15 const char kPrinterDescValue[] = "description";
     16 const char kPrinterCapsValue[] = "capabilities";
     17 const char kPrinterDisplayNameValue[] = "default_display_name";
     18 const char kPrinterDefaultsValue[] = "defaults";
     19 const char kPrinterStatusValue[] = "status";
     20 const char kPrinterTagValue[] = "tag";
     21 const char kPrinterRemoveTagValue[] = "remove_tag";
     22 const char kPrinterLocalSettingsValue[] = "local_settings";
     23 const char kMessageTextValue[] = "message";
     24 const char kUseCDD[] = "use_cdd";
     25 
     26 const char kContentTypeJSON[] = "application/json";
     27 const char kContentTypePDF[] = "application/pdf";
     28 const char kContentTypeXML[] = "application/xml";
     29 const char kContentTypeXPS[] = "application/vnd.ms-xpsdocument";
     30 
     31 const char kPrintSystemFailedMessageId[] = "printsystemfail";
     32 const char kGetPrinterCapsFailedMessageId[] = "getprncapsfail";
     33 const char kEnumPrintersFailedMessageId[] = "enumfail";
     34 const char kZombiePrinterMessageId[] = "zombieprinter";
     35 
     36 const char kSuccessValue[] = "success";
     37 const char kNameValue[] = "name";
     38 const char kDisplayNameValue[] = "displayName";
     39 const char kIdValue[] = "id";
     40 const char kTicketUrlValue[] = "ticketUrl";
     41 const char kFileUrlValue[] = "fileUrl";
     42 const char kPrinterListValue[] = "printers";
     43 const char kJobListValue[] = "jobs";
     44 const char kTitleValue[] = "title";
     45 const char kPrinterCapsHashValue[] = "capsHash";
     46 const char kTagsValue[] = "tags";
     47 const char kXMPPJidValue[] = "xmpp_jid";
     48 const char kOAuthCodeValue[] = "authorization_code";
     49 const char kCreateTimeValue[] = "createTime";
     50 const char kPrinterTypeValue[] = "type";
     51 const char kUserValue[] = "request.user";
     52 const char kUsersValue[] = "request.users";
     53 const char kLocalSettingsPendingXmppValue[] =
     54     "local_settings.pending.xmpp_timeout_value";
     55 
     56 const char kNotificationUpdateSettings[] = "/update_settings";
     57 
     58 const char kChromeVersionTagName[] = "chrome_version";
     59 const char kSystemNameTagName[] = "system_name";
     60 const char kSystemVersionTagName[] = "system_version";
     61 
     62 const char kCloudPrintServiceProxyTagPrefix[] = "__cp__";
     63 const char kCloudPrintServiceTagsHashTagName[] = "__cp__tagshash";
     64 const char kCloudPrintServiceTagDryRunFlag[] = "__cp__dry_run";
     65 
     66 const char kJobFetchReasonStartup[] = "startup";
     67 const char kJobFetchReasonPoll[] = "poll";
     68 const char kJobFetchReasonNotified[] = "notified";
     69 const char kJobFetchReasonQueryMore[] = "querymore";
     70 const char kJobFetchReasonFailure[] = "failure";
     71 const char kJobFetchReasonRetry[] = "retry";
     72 
     73 const char kCreateLocalSettingsXmppPingFormat[] =
     74     "{\"current\":{\"xmpp_timeout_value\": %d}}";
     75 const char kUpdateLocalSettingsXmppPingFormat[] =
     76     "{\"current\":{\"xmpp_timeout_value\": %d},\"pending\":{}}";
     77 
     78 }  // namespace cloud_print
     79