speed_reading_interval.proto 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. // Copyright 2022 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.maps.routing.v2;
  16. option cc_enable_arenas = true;
  17. option csharp_namespace = "Google.Maps.Routing.V2";
  18. option go_package = "google.golang.org/genproto/googleapis/maps/routing/v2;routing";
  19. option java_multiple_files = true;
  20. option java_outer_classname = "SpeedReadingIntervalProto";
  21. option java_package = "com.google.maps.routing.v2";
  22. option objc_class_prefix = "GMRV2";
  23. option php_namespace = "Google\\Maps\\Routing\\V2";
  24. option ruby_package = "Google::Maps::Routing::V2";
  25. // Traffic density indicator on a contiguous segment of a polyline or path.
  26. // Given a path with points P_0, P_1, ... , P_N (zero-based index), the
  27. // SpeedReadingInterval defines an interval and describes its traffic using the
  28. // following categories.
  29. message SpeedReadingInterval {
  30. // The classification of polyline speed based on traffic data.
  31. enum Speed {
  32. // Default value. This value is unused.
  33. SPEED_UNSPECIFIED = 0;
  34. // Normal speed, no slowdown is detected.
  35. NORMAL = 1;
  36. // Slowdown detected, but no traffic jam formed.
  37. SLOW = 2;
  38. // Traffic jam detected.
  39. TRAFFIC_JAM = 3;
  40. }
  41. // The starting index of this interval in the polyline.
  42. optional int32 start_polyline_point_index = 1;
  43. // The ending index of this interval in the polyline.
  44. optional int32 end_polyline_point_index = 2;
  45. // Traffic speed in this interval.
  46. Speed speed = 3;
  47. }