dates.proto 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. // Copyright 2021 Google LLC
  2. //
  3. // Licensed under the Apache License, Version 2.0 (the "License");
  4. // you may not use this file except in compliance with the License.
  5. // You may obtain a copy of the License at
  6. //
  7. // http://www.apache.org/licenses/LICENSE-2.0
  8. //
  9. // Unless required by applicable law or agreed to in writing, software
  10. // distributed under the License is distributed on an "AS IS" BASIS,
  11. // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. // See the License for the specific language governing permissions and
  13. // limitations under the License.
  14. syntax = "proto3";
  15. package google.ads.googleads.v8.common;
  16. import "google/ads/googleads/v8/enums/month_of_year.proto";
  17. import "google/api/annotations.proto";
  18. option csharp_namespace = "Google.Ads.GoogleAds.V8.Common";
  19. option go_package = "google.golang.org/genproto/googleapis/ads/googleads/v8/common;common";
  20. option java_multiple_files = true;
  21. option java_outer_classname = "DatesProto";
  22. option java_package = "com.google.ads.googleads.v8.common";
  23. option objc_class_prefix = "GAA";
  24. option php_namespace = "Google\\Ads\\GoogleAds\\V8\\Common";
  25. option ruby_package = "Google::Ads::GoogleAds::V8::Common";
  26. // Proto file describing date range message.
  27. // A date range.
  28. message DateRange {
  29. // The start date, in yyyy-mm-dd format. This date is inclusive.
  30. optional string start_date = 3;
  31. // The end date, in yyyy-mm-dd format. This date is inclusive.
  32. optional string end_date = 4;
  33. }
  34. // The year month range inclusive of the start and end months.
  35. // Eg: A year month range to represent Jan 2020 would be: (Jan 2020, Jan 2020).
  36. message YearMonthRange {
  37. // The inclusive start year month.
  38. YearMonth start = 1;
  39. // The inclusive end year month.
  40. YearMonth end = 2;
  41. }
  42. // Year month.
  43. message YearMonth {
  44. // The year (e.g. 2020).
  45. int64 year = 1;
  46. // The month of the year. (e.g. FEBRUARY).
  47. google.ads.googleads.v8.enums.MonthOfYearEnum.MonthOfYear month = 2;
  48. }