Class: Google::Cloud::Optimization::V1::Shipment

Inherits:
Object
  • Object
show all
Extended by:
Protobuf::MessageExts::ClassMethods
Includes:
Protobuf::MessageExts
Defined in:
proto_docs/google/cloud/optimization/v1/fleet_routing.rb

Overview

The shipment of a single item, from one of its pickups to one of its deliveries. For the shipment to be considered as performed, a unique vehicle must visit one of its pickup locations (and decrease its spare capacities accordingly), then visit one of its delivery locations later on (and therefore re-increase its spare capacities accordingly).

Defined Under Namespace

Classes: Load, LoadDemandsEntry, VisitRequest

Instance Attribute Summary collapse

Instance Attribute Details

#allowed_vehicle_indices::Array<::Integer>



913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
# File 'proto_docs/google/cloud/optimization/v1/fleet_routing.rb', line 913

class Shipment
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Request for a visit which can be done by a vehicle: it has a geo-location
  # (or two, see below), opening and closing times represented by time windows,
  # and a service duration time (time spent by the vehicle once it has arrived
  # to pickup or drop off goods).
  # @!attribute [rw] arrival_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_location` must not be specified.
  # @!attribute [rw] arrival_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_waypoint` must not be specified.
  # @!attribute [rw] departure_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_location`.
  #     If the shipment model has duration distance matrices,
  #     `departure_location` must not be specified.
  # @!attribute [rw] departure_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_waypoint`.
  #     If the shipment model has duration distance matrices,
  #     `departure_waypoint` must not be specified.
  # @!attribute [rw] tags
  #   @return [::Array<::String>]
  #     Specifies tags attached to the visit request.
  #     Empty or duplicate strings are not allowed.
  # @!attribute [rw] time_windows
  #   @return [::Array<::Google::Cloud::Optimization::V1::TimeWindow>]
  #     Time windows which constrain the arrival time at a visit.
  #     Note that a vehicle may depart outside of the arrival time window, i.e.
  #     arrival time + duration do not need to be inside a time window. This can
  #     result in waiting time if the vehicle arrives before
  #     {::Google::Cloud::Optimization::V1::TimeWindow#start_time TimeWindow.start_time}.
  #
  #     The absence of `TimeWindow` means that the vehicle can perform this visit
  #     at any time.
  #
  #     Time windows must be disjoint, i.e. no time window must overlap with or
  #     be adjacent to another, and they must be in increasing order.
  #
  #     `cost_per_hour_after_soft_end_time` and `soft_end_time` can only
  #     be set if there is a single time window.
  # @!attribute [rw] duration
  #   @return [::Google::Protobuf::Duration]
  #     Duration of the visit, i.e. time spent by the vehicle between arrival
  #     and departure (to be added to the possible waiting time; see
  #     `time_windows`).
  # @!attribute [rw] cost
  #   @return [::Float]
  #     Cost to service this visit request on a vehicle route. This can be used
  #     to pay different costs for each alternative pickup or delivery of a
  #     shipment. This cost must be in the same unit as `Shipment.penalty_cost`
  #     and must not be negative.
  # @!attribute [rw] load_demands
  #   @return [::Google::Protobuf::Map{::String => ::Google::Cloud::Optimization::V1::Shipment::Load}]
  #     Load demands of this visit request. This is just like
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}
  #     field, except that it only applies to this
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest VisitRequest}
  #     instead of the whole {::Google::Cloud::Optimization::V1::Shipment Shipment}.
  #     The demands listed here are added to the demands listed in
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}.
  # @!attribute [rw] visit_types
  #   @return [::Array<::String>]
  #     Specifies the types of the visit. This may be used to allocate additional
  #     time required for a vehicle to complete this visit (see
  #     {::Google::Cloud::Optimization::V1::Vehicle#extra_visit_duration_for_visit_type Vehicle.extra_visit_duration_for_visit_type}).
  #
  #     A type can only appear once.
  # @!attribute [rw] label
  #   @return [::String]
  #     Specifies a label for this `VisitRequest`. This label is reported in the
  #     response as `visit_label` in the corresponding
  #     {::Google::Cloud::Optimization::V1::ShipmentRoute::Visit ShipmentRoute.Visit}.
  # @!attribute [rw] demands
  #   @deprecated This field is deprecated and may be removed in the next major version update.
  #   @return [::Array<::Google::Cloud::Optimization::V1::CapacityQuantity>]
  #     Deprecated: Use
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest#load_demands VisitRequest.load_demands}
  #     instead.
  class VisitRequest
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # @!attribute [rw] key
    #   @return [::String]
    # @!attribute [rw] value
    #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
    class LoadDemandsEntry
      include ::Google::Protobuf::MessageExts
      extend ::Google::Protobuf::MessageExts::ClassMethods
    end
  end

  # When performing a visit, a predefined amount may be added to the vehicle
  # load if it's a pickup, or subtracted if it's a delivery. This message
  # defines such amount. See
  # {::Google::Cloud::Optimization::V1::Shipment#load_demands load_demands}.
  # @!attribute [rw] amount
  #   @return [::Integer]
  #     The amount by which the load of the vehicle performing the corresponding
  #     visit will vary. Since it is an integer, users are advised to choose an
  #     appropriate unit to avoid loss of precision. Must be ≥ 0.
  class Load
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
  class LoadDemandsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#costs_per_vehicle::Array<::Float>



913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
# File 'proto_docs/google/cloud/optimization/v1/fleet_routing.rb', line 913

class Shipment
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Request for a visit which can be done by a vehicle: it has a geo-location
  # (or two, see below), opening and closing times represented by time windows,
  # and a service duration time (time spent by the vehicle once it has arrived
  # to pickup or drop off goods).
  # @!attribute [rw] arrival_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_location` must not be specified.
  # @!attribute [rw] arrival_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_waypoint` must not be specified.
  # @!attribute [rw] departure_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_location`.
  #     If the shipment model has duration distance matrices,
  #     `departure_location` must not be specified.
  # @!attribute [rw] departure_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_waypoint`.
  #     If the shipment model has duration distance matrices,
  #     `departure_waypoint` must not be specified.
  # @!attribute [rw] tags
  #   @return [::Array<::String>]
  #     Specifies tags attached to the visit request.
  #     Empty or duplicate strings are not allowed.
  # @!attribute [rw] time_windows
  #   @return [::Array<::Google::Cloud::Optimization::V1::TimeWindow>]
  #     Time windows which constrain the arrival time at a visit.
  #     Note that a vehicle may depart outside of the arrival time window, i.e.
  #     arrival time + duration do not need to be inside a time window. This can
  #     result in waiting time if the vehicle arrives before
  #     {::Google::Cloud::Optimization::V1::TimeWindow#start_time TimeWindow.start_time}.
  #
  #     The absence of `TimeWindow` means that the vehicle can perform this visit
  #     at any time.
  #
  #     Time windows must be disjoint, i.e. no time window must overlap with or
  #     be adjacent to another, and they must be in increasing order.
  #
  #     `cost_per_hour_after_soft_end_time` and `soft_end_time` can only
  #     be set if there is a single time window.
  # @!attribute [rw] duration
  #   @return [::Google::Protobuf::Duration]
  #     Duration of the visit, i.e. time spent by the vehicle between arrival
  #     and departure (to be added to the possible waiting time; see
  #     `time_windows`).
  # @!attribute [rw] cost
  #   @return [::Float]
  #     Cost to service this visit request on a vehicle route. This can be used
  #     to pay different costs for each alternative pickup or delivery of a
  #     shipment. This cost must be in the same unit as `Shipment.penalty_cost`
  #     and must not be negative.
  # @!attribute [rw] load_demands
  #   @return [::Google::Protobuf::Map{::String => ::Google::Cloud::Optimization::V1::Shipment::Load}]
  #     Load demands of this visit request. This is just like
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}
  #     field, except that it only applies to this
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest VisitRequest}
  #     instead of the whole {::Google::Cloud::Optimization::V1::Shipment Shipment}.
  #     The demands listed here are added to the demands listed in
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}.
  # @!attribute [rw] visit_types
  #   @return [::Array<::String>]
  #     Specifies the types of the visit. This may be used to allocate additional
  #     time required for a vehicle to complete this visit (see
  #     {::Google::Cloud::Optimization::V1::Vehicle#extra_visit_duration_for_visit_type Vehicle.extra_visit_duration_for_visit_type}).
  #
  #     A type can only appear once.
  # @!attribute [rw] label
  #   @return [::String]
  #     Specifies a label for this `VisitRequest`. This label is reported in the
  #     response as `visit_label` in the corresponding
  #     {::Google::Cloud::Optimization::V1::ShipmentRoute::Visit ShipmentRoute.Visit}.
  # @!attribute [rw] demands
  #   @deprecated This field is deprecated and may be removed in the next major version update.
  #   @return [::Array<::Google::Cloud::Optimization::V1::CapacityQuantity>]
  #     Deprecated: Use
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest#load_demands VisitRequest.load_demands}
  #     instead.
  class VisitRequest
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # @!attribute [rw] key
    #   @return [::String]
    # @!attribute [rw] value
    #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
    class LoadDemandsEntry
      include ::Google::Protobuf::MessageExts
      extend ::Google::Protobuf::MessageExts::ClassMethods
    end
  end

  # When performing a visit, a predefined amount may be added to the vehicle
  # load if it's a pickup, or subtracted if it's a delivery. This message
  # defines such amount. See
  # {::Google::Cloud::Optimization::V1::Shipment#load_demands load_demands}.
  # @!attribute [rw] amount
  #   @return [::Integer]
  #     The amount by which the load of the vehicle performing the corresponding
  #     visit will vary. Since it is an integer, users are advised to choose an
  #     appropriate unit to avoid loss of precision. Must be ≥ 0.
  class Load
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
  class LoadDemandsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#costs_per_vehicle_indices::Array<::Integer>



913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
# File 'proto_docs/google/cloud/optimization/v1/fleet_routing.rb', line 913

class Shipment
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Request for a visit which can be done by a vehicle: it has a geo-location
  # (or two, see below), opening and closing times represented by time windows,
  # and a service duration time (time spent by the vehicle once it has arrived
  # to pickup or drop off goods).
  # @!attribute [rw] arrival_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_location` must not be specified.
  # @!attribute [rw] arrival_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_waypoint` must not be specified.
  # @!attribute [rw] departure_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_location`.
  #     If the shipment model has duration distance matrices,
  #     `departure_location` must not be specified.
  # @!attribute [rw] departure_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_waypoint`.
  #     If the shipment model has duration distance matrices,
  #     `departure_waypoint` must not be specified.
  # @!attribute [rw] tags
  #   @return [::Array<::String>]
  #     Specifies tags attached to the visit request.
  #     Empty or duplicate strings are not allowed.
  # @!attribute [rw] time_windows
  #   @return [::Array<::Google::Cloud::Optimization::V1::TimeWindow>]
  #     Time windows which constrain the arrival time at a visit.
  #     Note that a vehicle may depart outside of the arrival time window, i.e.
  #     arrival time + duration do not need to be inside a time window. This can
  #     result in waiting time if the vehicle arrives before
  #     {::Google::Cloud::Optimization::V1::TimeWindow#start_time TimeWindow.start_time}.
  #
  #     The absence of `TimeWindow` means that the vehicle can perform this visit
  #     at any time.
  #
  #     Time windows must be disjoint, i.e. no time window must overlap with or
  #     be adjacent to another, and they must be in increasing order.
  #
  #     `cost_per_hour_after_soft_end_time` and `soft_end_time` can only
  #     be set if there is a single time window.
  # @!attribute [rw] duration
  #   @return [::Google::Protobuf::Duration]
  #     Duration of the visit, i.e. time spent by the vehicle between arrival
  #     and departure (to be added to the possible waiting time; see
  #     `time_windows`).
  # @!attribute [rw] cost
  #   @return [::Float]
  #     Cost to service this visit request on a vehicle route. This can be used
  #     to pay different costs for each alternative pickup or delivery of a
  #     shipment. This cost must be in the same unit as `Shipment.penalty_cost`
  #     and must not be negative.
  # @!attribute [rw] load_demands
  #   @return [::Google::Protobuf::Map{::String => ::Google::Cloud::Optimization::V1::Shipment::Load}]
  #     Load demands of this visit request. This is just like
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}
  #     field, except that it only applies to this
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest VisitRequest}
  #     instead of the whole {::Google::Cloud::Optimization::V1::Shipment Shipment}.
  #     The demands listed here are added to the demands listed in
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}.
  # @!attribute [rw] visit_types
  #   @return [::Array<::String>]
  #     Specifies the types of the visit. This may be used to allocate additional
  #     time required for a vehicle to complete this visit (see
  #     {::Google::Cloud::Optimization::V1::Vehicle#extra_visit_duration_for_visit_type Vehicle.extra_visit_duration_for_visit_type}).
  #
  #     A type can only appear once.
  # @!attribute [rw] label
  #   @return [::String]
  #     Specifies a label for this `VisitRequest`. This label is reported in the
  #     response as `visit_label` in the corresponding
  #     {::Google::Cloud::Optimization::V1::ShipmentRoute::Visit ShipmentRoute.Visit}.
  # @!attribute [rw] demands
  #   @deprecated This field is deprecated and may be removed in the next major version update.
  #   @return [::Array<::Google::Cloud::Optimization::V1::CapacityQuantity>]
  #     Deprecated: Use
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest#load_demands VisitRequest.load_demands}
  #     instead.
  class VisitRequest
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # @!attribute [rw] key
    #   @return [::String]
    # @!attribute [rw] value
    #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
    class LoadDemandsEntry
      include ::Google::Protobuf::MessageExts
      extend ::Google::Protobuf::MessageExts::ClassMethods
    end
  end

  # When performing a visit, a predefined amount may be added to the vehicle
  # load if it's a pickup, or subtracted if it's a delivery. This message
  # defines such amount. See
  # {::Google::Cloud::Optimization::V1::Shipment#load_demands load_demands}.
  # @!attribute [rw] amount
  #   @return [::Integer]
  #     The amount by which the load of the vehicle performing the corresponding
  #     visit will vary. Since it is an integer, users are advised to choose an
  #     appropriate unit to avoid loss of precision. Must be ≥ 0.
  class Load
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
  class LoadDemandsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#deliveries::Array<::Google::Cloud::Optimization::V1::Shipment::VisitRequest>



913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
# File 'proto_docs/google/cloud/optimization/v1/fleet_routing.rb', line 913

class Shipment
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Request for a visit which can be done by a vehicle: it has a geo-location
  # (or two, see below), opening and closing times represented by time windows,
  # and a service duration time (time spent by the vehicle once it has arrived
  # to pickup or drop off goods).
  # @!attribute [rw] arrival_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_location` must not be specified.
  # @!attribute [rw] arrival_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_waypoint` must not be specified.
  # @!attribute [rw] departure_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_location`.
  #     If the shipment model has duration distance matrices,
  #     `departure_location` must not be specified.
  # @!attribute [rw] departure_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_waypoint`.
  #     If the shipment model has duration distance matrices,
  #     `departure_waypoint` must not be specified.
  # @!attribute [rw] tags
  #   @return [::Array<::String>]
  #     Specifies tags attached to the visit request.
  #     Empty or duplicate strings are not allowed.
  # @!attribute [rw] time_windows
  #   @return [::Array<::Google::Cloud::Optimization::V1::TimeWindow>]
  #     Time windows which constrain the arrival time at a visit.
  #     Note that a vehicle may depart outside of the arrival time window, i.e.
  #     arrival time + duration do not need to be inside a time window. This can
  #     result in waiting time if the vehicle arrives before
  #     {::Google::Cloud::Optimization::V1::TimeWindow#start_time TimeWindow.start_time}.
  #
  #     The absence of `TimeWindow` means that the vehicle can perform this visit
  #     at any time.
  #
  #     Time windows must be disjoint, i.e. no time window must overlap with or
  #     be adjacent to another, and they must be in increasing order.
  #
  #     `cost_per_hour_after_soft_end_time` and `soft_end_time` can only
  #     be set if there is a single time window.
  # @!attribute [rw] duration
  #   @return [::Google::Protobuf::Duration]
  #     Duration of the visit, i.e. time spent by the vehicle between arrival
  #     and departure (to be added to the possible waiting time; see
  #     `time_windows`).
  # @!attribute [rw] cost
  #   @return [::Float]
  #     Cost to service this visit request on a vehicle route. This can be used
  #     to pay different costs for each alternative pickup or delivery of a
  #     shipment. This cost must be in the same unit as `Shipment.penalty_cost`
  #     and must not be negative.
  # @!attribute [rw] load_demands
  #   @return [::Google::Protobuf::Map{::String => ::Google::Cloud::Optimization::V1::Shipment::Load}]
  #     Load demands of this visit request. This is just like
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}
  #     field, except that it only applies to this
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest VisitRequest}
  #     instead of the whole {::Google::Cloud::Optimization::V1::Shipment Shipment}.
  #     The demands listed here are added to the demands listed in
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}.
  # @!attribute [rw] visit_types
  #   @return [::Array<::String>]
  #     Specifies the types of the visit. This may be used to allocate additional
  #     time required for a vehicle to complete this visit (see
  #     {::Google::Cloud::Optimization::V1::Vehicle#extra_visit_duration_for_visit_type Vehicle.extra_visit_duration_for_visit_type}).
  #
  #     A type can only appear once.
  # @!attribute [rw] label
  #   @return [::String]
  #     Specifies a label for this `VisitRequest`. This label is reported in the
  #     response as `visit_label` in the corresponding
  #     {::Google::Cloud::Optimization::V1::ShipmentRoute::Visit ShipmentRoute.Visit}.
  # @!attribute [rw] demands
  #   @deprecated This field is deprecated and may be removed in the next major version update.
  #   @return [::Array<::Google::Cloud::Optimization::V1::CapacityQuantity>]
  #     Deprecated: Use
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest#load_demands VisitRequest.load_demands}
  #     instead.
  class VisitRequest
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # @!attribute [rw] key
    #   @return [::String]
    # @!attribute [rw] value
    #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
    class LoadDemandsEntry
      include ::Google::Protobuf::MessageExts
      extend ::Google::Protobuf::MessageExts::ClassMethods
    end
  end

  # When performing a visit, a predefined amount may be added to the vehicle
  # load if it's a pickup, or subtracted if it's a delivery. This message
  # defines such amount. See
  # {::Google::Cloud::Optimization::V1::Shipment#load_demands load_demands}.
  # @!attribute [rw] amount
  #   @return [::Integer]
  #     The amount by which the load of the vehicle performing the corresponding
  #     visit will vary. Since it is an integer, users are advised to choose an
  #     appropriate unit to avoid loss of precision. Must be ≥ 0.
  class Load
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
  class LoadDemandsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#demands::Array<::Google::Cloud::Optimization::V1::CapacityQuantity>

Deprecated.

This field is deprecated and may be removed in the next major version update.

Returns Deprecated: Use Shipment.load_demands instead.



913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
# File 'proto_docs/google/cloud/optimization/v1/fleet_routing.rb', line 913

class Shipment
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Request for a visit which can be done by a vehicle: it has a geo-location
  # (or two, see below), opening and closing times represented by time windows,
  # and a service duration time (time spent by the vehicle once it has arrived
  # to pickup or drop off goods).
  # @!attribute [rw] arrival_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_location` must not be specified.
  # @!attribute [rw] arrival_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_waypoint` must not be specified.
  # @!attribute [rw] departure_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_location`.
  #     If the shipment model has duration distance matrices,
  #     `departure_location` must not be specified.
  # @!attribute [rw] departure_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_waypoint`.
  #     If the shipment model has duration distance matrices,
  #     `departure_waypoint` must not be specified.
  # @!attribute [rw] tags
  #   @return [::Array<::String>]
  #     Specifies tags attached to the visit request.
  #     Empty or duplicate strings are not allowed.
  # @!attribute [rw] time_windows
  #   @return [::Array<::Google::Cloud::Optimization::V1::TimeWindow>]
  #     Time windows which constrain the arrival time at a visit.
  #     Note that a vehicle may depart outside of the arrival time window, i.e.
  #     arrival time + duration do not need to be inside a time window. This can
  #     result in waiting time if the vehicle arrives before
  #     {::Google::Cloud::Optimization::V1::TimeWindow#start_time TimeWindow.start_time}.
  #
  #     The absence of `TimeWindow` means that the vehicle can perform this visit
  #     at any time.
  #
  #     Time windows must be disjoint, i.e. no time window must overlap with or
  #     be adjacent to another, and they must be in increasing order.
  #
  #     `cost_per_hour_after_soft_end_time` and `soft_end_time` can only
  #     be set if there is a single time window.
  # @!attribute [rw] duration
  #   @return [::Google::Protobuf::Duration]
  #     Duration of the visit, i.e. time spent by the vehicle between arrival
  #     and departure (to be added to the possible waiting time; see
  #     `time_windows`).
  # @!attribute [rw] cost
  #   @return [::Float]
  #     Cost to service this visit request on a vehicle route. This can be used
  #     to pay different costs for each alternative pickup or delivery of a
  #     shipment. This cost must be in the same unit as `Shipment.penalty_cost`
  #     and must not be negative.
  # @!attribute [rw] load_demands
  #   @return [::Google::Protobuf::Map{::String => ::Google::Cloud::Optimization::V1::Shipment::Load}]
  #     Load demands of this visit request. This is just like
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}
  #     field, except that it only applies to this
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest VisitRequest}
  #     instead of the whole {::Google::Cloud::Optimization::V1::Shipment Shipment}.
  #     The demands listed here are added to the demands listed in
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}.
  # @!attribute [rw] visit_types
  #   @return [::Array<::String>]
  #     Specifies the types of the visit. This may be used to allocate additional
  #     time required for a vehicle to complete this visit (see
  #     {::Google::Cloud::Optimization::V1::Vehicle#extra_visit_duration_for_visit_type Vehicle.extra_visit_duration_for_visit_type}).
  #
  #     A type can only appear once.
  # @!attribute [rw] label
  #   @return [::String]
  #     Specifies a label for this `VisitRequest`. This label is reported in the
  #     response as `visit_label` in the corresponding
  #     {::Google::Cloud::Optimization::V1::ShipmentRoute::Visit ShipmentRoute.Visit}.
  # @!attribute [rw] demands
  #   @deprecated This field is deprecated and may be removed in the next major version update.
  #   @return [::Array<::Google::Cloud::Optimization::V1::CapacityQuantity>]
  #     Deprecated: Use
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest#load_demands VisitRequest.load_demands}
  #     instead.
  class VisitRequest
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # @!attribute [rw] key
    #   @return [::String]
    # @!attribute [rw] value
    #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
    class LoadDemandsEntry
      include ::Google::Protobuf::MessageExts
      extend ::Google::Protobuf::MessageExts::ClassMethods
    end
  end

  # When performing a visit, a predefined amount may be added to the vehicle
  # load if it's a pickup, or subtracted if it's a delivery. This message
  # defines such amount. See
  # {::Google::Cloud::Optimization::V1::Shipment#load_demands load_demands}.
  # @!attribute [rw] amount
  #   @return [::Integer]
  #     The amount by which the load of the vehicle performing the corresponding
  #     visit will vary. Since it is an integer, users are advised to choose an
  #     appropriate unit to avoid loss of precision. Must be ≥ 0.
  class Load
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
  class LoadDemandsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#ignore::Boolean



913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
# File 'proto_docs/google/cloud/optimization/v1/fleet_routing.rb', line 913

class Shipment
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Request for a visit which can be done by a vehicle: it has a geo-location
  # (or two, see below), opening and closing times represented by time windows,
  # and a service duration time (time spent by the vehicle once it has arrived
  # to pickup or drop off goods).
  # @!attribute [rw] arrival_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_location` must not be specified.
  # @!attribute [rw] arrival_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_waypoint` must not be specified.
  # @!attribute [rw] departure_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_location`.
  #     If the shipment model has duration distance matrices,
  #     `departure_location` must not be specified.
  # @!attribute [rw] departure_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_waypoint`.
  #     If the shipment model has duration distance matrices,
  #     `departure_waypoint` must not be specified.
  # @!attribute [rw] tags
  #   @return [::Array<::String>]
  #     Specifies tags attached to the visit request.
  #     Empty or duplicate strings are not allowed.
  # @!attribute [rw] time_windows
  #   @return [::Array<::Google::Cloud::Optimization::V1::TimeWindow>]
  #     Time windows which constrain the arrival time at a visit.
  #     Note that a vehicle may depart outside of the arrival time window, i.e.
  #     arrival time + duration do not need to be inside a time window. This can
  #     result in waiting time if the vehicle arrives before
  #     {::Google::Cloud::Optimization::V1::TimeWindow#start_time TimeWindow.start_time}.
  #
  #     The absence of `TimeWindow` means that the vehicle can perform this visit
  #     at any time.
  #
  #     Time windows must be disjoint, i.e. no time window must overlap with or
  #     be adjacent to another, and they must be in increasing order.
  #
  #     `cost_per_hour_after_soft_end_time` and `soft_end_time` can only
  #     be set if there is a single time window.
  # @!attribute [rw] duration
  #   @return [::Google::Protobuf::Duration]
  #     Duration of the visit, i.e. time spent by the vehicle between arrival
  #     and departure (to be added to the possible waiting time; see
  #     `time_windows`).
  # @!attribute [rw] cost
  #   @return [::Float]
  #     Cost to service this visit request on a vehicle route. This can be used
  #     to pay different costs for each alternative pickup or delivery of a
  #     shipment. This cost must be in the same unit as `Shipment.penalty_cost`
  #     and must not be negative.
  # @!attribute [rw] load_demands
  #   @return [::Google::Protobuf::Map{::String => ::Google::Cloud::Optimization::V1::Shipment::Load}]
  #     Load demands of this visit request. This is just like
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}
  #     field, except that it only applies to this
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest VisitRequest}
  #     instead of the whole {::Google::Cloud::Optimization::V1::Shipment Shipment}.
  #     The demands listed here are added to the demands listed in
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}.
  # @!attribute [rw] visit_types
  #   @return [::Array<::String>]
  #     Specifies the types of the visit. This may be used to allocate additional
  #     time required for a vehicle to complete this visit (see
  #     {::Google::Cloud::Optimization::V1::Vehicle#extra_visit_duration_for_visit_type Vehicle.extra_visit_duration_for_visit_type}).
  #
  #     A type can only appear once.
  # @!attribute [rw] label
  #   @return [::String]
  #     Specifies a label for this `VisitRequest`. This label is reported in the
  #     response as `visit_label` in the corresponding
  #     {::Google::Cloud::Optimization::V1::ShipmentRoute::Visit ShipmentRoute.Visit}.
  # @!attribute [rw] demands
  #   @deprecated This field is deprecated and may be removed in the next major version update.
  #   @return [::Array<::Google::Cloud::Optimization::V1::CapacityQuantity>]
  #     Deprecated: Use
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest#load_demands VisitRequest.load_demands}
  #     instead.
  class VisitRequest
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # @!attribute [rw] key
    #   @return [::String]
    # @!attribute [rw] value
    #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
    class LoadDemandsEntry
      include ::Google::Protobuf::MessageExts
      extend ::Google::Protobuf::MessageExts::ClassMethods
    end
  end

  # When performing a visit, a predefined amount may be added to the vehicle
  # load if it's a pickup, or subtracted if it's a delivery. This message
  # defines such amount. See
  # {::Google::Cloud::Optimization::V1::Shipment#load_demands load_demands}.
  # @!attribute [rw] amount
  #   @return [::Integer]
  #     The amount by which the load of the vehicle performing the corresponding
  #     visit will vary. Since it is an integer, users are advised to choose an
  #     appropriate unit to avoid loss of precision. Must be ≥ 0.
  class Load
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
  class LoadDemandsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#label::String



913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
# File 'proto_docs/google/cloud/optimization/v1/fleet_routing.rb', line 913

class Shipment
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Request for a visit which can be done by a vehicle: it has a geo-location
  # (or two, see below), opening and closing times represented by time windows,
  # and a service duration time (time spent by the vehicle once it has arrived
  # to pickup or drop off goods).
  # @!attribute [rw] arrival_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_location` must not be specified.
  # @!attribute [rw] arrival_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_waypoint` must not be specified.
  # @!attribute [rw] departure_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_location`.
  #     If the shipment model has duration distance matrices,
  #     `departure_location` must not be specified.
  # @!attribute [rw] departure_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_waypoint`.
  #     If the shipment model has duration distance matrices,
  #     `departure_waypoint` must not be specified.
  # @!attribute [rw] tags
  #   @return [::Array<::String>]
  #     Specifies tags attached to the visit request.
  #     Empty or duplicate strings are not allowed.
  # @!attribute [rw] time_windows
  #   @return [::Array<::Google::Cloud::Optimization::V1::TimeWindow>]
  #     Time windows which constrain the arrival time at a visit.
  #     Note that a vehicle may depart outside of the arrival time window, i.e.
  #     arrival time + duration do not need to be inside a time window. This can
  #     result in waiting time if the vehicle arrives before
  #     {::Google::Cloud::Optimization::V1::TimeWindow#start_time TimeWindow.start_time}.
  #
  #     The absence of `TimeWindow` means that the vehicle can perform this visit
  #     at any time.
  #
  #     Time windows must be disjoint, i.e. no time window must overlap with or
  #     be adjacent to another, and they must be in increasing order.
  #
  #     `cost_per_hour_after_soft_end_time` and `soft_end_time` can only
  #     be set if there is a single time window.
  # @!attribute [rw] duration
  #   @return [::Google::Protobuf::Duration]
  #     Duration of the visit, i.e. time spent by the vehicle between arrival
  #     and departure (to be added to the possible waiting time; see
  #     `time_windows`).
  # @!attribute [rw] cost
  #   @return [::Float]
  #     Cost to service this visit request on a vehicle route. This can be used
  #     to pay different costs for each alternative pickup or delivery of a
  #     shipment. This cost must be in the same unit as `Shipment.penalty_cost`
  #     and must not be negative.
  # @!attribute [rw] load_demands
  #   @return [::Google::Protobuf::Map{::String => ::Google::Cloud::Optimization::V1::Shipment::Load}]
  #     Load demands of this visit request. This is just like
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}
  #     field, except that it only applies to this
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest VisitRequest}
  #     instead of the whole {::Google::Cloud::Optimization::V1::Shipment Shipment}.
  #     The demands listed here are added to the demands listed in
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}.
  # @!attribute [rw] visit_types
  #   @return [::Array<::String>]
  #     Specifies the types of the visit. This may be used to allocate additional
  #     time required for a vehicle to complete this visit (see
  #     {::Google::Cloud::Optimization::V1::Vehicle#extra_visit_duration_for_visit_type Vehicle.extra_visit_duration_for_visit_type}).
  #
  #     A type can only appear once.
  # @!attribute [rw] label
  #   @return [::String]
  #     Specifies a label for this `VisitRequest`. This label is reported in the
  #     response as `visit_label` in the corresponding
  #     {::Google::Cloud::Optimization::V1::ShipmentRoute::Visit ShipmentRoute.Visit}.
  # @!attribute [rw] demands
  #   @deprecated This field is deprecated and may be removed in the next major version update.
  #   @return [::Array<::Google::Cloud::Optimization::V1::CapacityQuantity>]
  #     Deprecated: Use
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest#load_demands VisitRequest.load_demands}
  #     instead.
  class VisitRequest
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # @!attribute [rw] key
    #   @return [::String]
    # @!attribute [rw] value
    #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
    class LoadDemandsEntry
      include ::Google::Protobuf::MessageExts
      extend ::Google::Protobuf::MessageExts::ClassMethods
    end
  end

  # When performing a visit, a predefined amount may be added to the vehicle
  # load if it's a pickup, or subtracted if it's a delivery. This message
  # defines such amount. See
  # {::Google::Cloud::Optimization::V1::Shipment#load_demands load_demands}.
  # @!attribute [rw] amount
  #   @return [::Integer]
  #     The amount by which the load of the vehicle performing the corresponding
  #     visit will vary. Since it is an integer, users are advised to choose an
  #     appropriate unit to avoid loss of precision. Must be ≥ 0.
  class Load
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
  class LoadDemandsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#load_demands::Google::Protobuf::Map{::String => ::Google::Cloud::Optimization::V1::Shipment::Load}



913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
# File 'proto_docs/google/cloud/optimization/v1/fleet_routing.rb', line 913

class Shipment
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Request for a visit which can be done by a vehicle: it has a geo-location
  # (or two, see below), opening and closing times represented by time windows,
  # and a service duration time (time spent by the vehicle once it has arrived
  # to pickup or drop off goods).
  # @!attribute [rw] arrival_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_location` must not be specified.
  # @!attribute [rw] arrival_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_waypoint` must not be specified.
  # @!attribute [rw] departure_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_location`.
  #     If the shipment model has duration distance matrices,
  #     `departure_location` must not be specified.
  # @!attribute [rw] departure_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_waypoint`.
  #     If the shipment model has duration distance matrices,
  #     `departure_waypoint` must not be specified.
  # @!attribute [rw] tags
  #   @return [::Array<::String>]
  #     Specifies tags attached to the visit request.
  #     Empty or duplicate strings are not allowed.
  # @!attribute [rw] time_windows
  #   @return [::Array<::Google::Cloud::Optimization::V1::TimeWindow>]
  #     Time windows which constrain the arrival time at a visit.
  #     Note that a vehicle may depart outside of the arrival time window, i.e.
  #     arrival time + duration do not need to be inside a time window. This can
  #     result in waiting time if the vehicle arrives before
  #     {::Google::Cloud::Optimization::V1::TimeWindow#start_time TimeWindow.start_time}.
  #
  #     The absence of `TimeWindow` means that the vehicle can perform this visit
  #     at any time.
  #
  #     Time windows must be disjoint, i.e. no time window must overlap with or
  #     be adjacent to another, and they must be in increasing order.
  #
  #     `cost_per_hour_after_soft_end_time` and `soft_end_time` can only
  #     be set if there is a single time window.
  # @!attribute [rw] duration
  #   @return [::Google::Protobuf::Duration]
  #     Duration of the visit, i.e. time spent by the vehicle between arrival
  #     and departure (to be added to the possible waiting time; see
  #     `time_windows`).
  # @!attribute [rw] cost
  #   @return [::Float]
  #     Cost to service this visit request on a vehicle route. This can be used
  #     to pay different costs for each alternative pickup or delivery of a
  #     shipment. This cost must be in the same unit as `Shipment.penalty_cost`
  #     and must not be negative.
  # @!attribute [rw] load_demands
  #   @return [::Google::Protobuf::Map{::String => ::Google::Cloud::Optimization::V1::Shipment::Load}]
  #     Load demands of this visit request. This is just like
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}
  #     field, except that it only applies to this
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest VisitRequest}
  #     instead of the whole {::Google::Cloud::Optimization::V1::Shipment Shipment}.
  #     The demands listed here are added to the demands listed in
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}.
  # @!attribute [rw] visit_types
  #   @return [::Array<::String>]
  #     Specifies the types of the visit. This may be used to allocate additional
  #     time required for a vehicle to complete this visit (see
  #     {::Google::Cloud::Optimization::V1::Vehicle#extra_visit_duration_for_visit_type Vehicle.extra_visit_duration_for_visit_type}).
  #
  #     A type can only appear once.
  # @!attribute [rw] label
  #   @return [::String]
  #     Specifies a label for this `VisitRequest`. This label is reported in the
  #     response as `visit_label` in the corresponding
  #     {::Google::Cloud::Optimization::V1::ShipmentRoute::Visit ShipmentRoute.Visit}.
  # @!attribute [rw] demands
  #   @deprecated This field is deprecated and may be removed in the next major version update.
  #   @return [::Array<::Google::Cloud::Optimization::V1::CapacityQuantity>]
  #     Deprecated: Use
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest#load_demands VisitRequest.load_demands}
  #     instead.
  class VisitRequest
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # @!attribute [rw] key
    #   @return [::String]
    # @!attribute [rw] value
    #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
    class LoadDemandsEntry
      include ::Google::Protobuf::MessageExts
      extend ::Google::Protobuf::MessageExts::ClassMethods
    end
  end

  # When performing a visit, a predefined amount may be added to the vehicle
  # load if it's a pickup, or subtracted if it's a delivery. This message
  # defines such amount. See
  # {::Google::Cloud::Optimization::V1::Shipment#load_demands load_demands}.
  # @!attribute [rw] amount
  #   @return [::Integer]
  #     The amount by which the load of the vehicle performing the corresponding
  #     visit will vary. Since it is an integer, users are advised to choose an
  #     appropriate unit to avoid loss of precision. Must be ≥ 0.
  class Load
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
  class LoadDemandsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#penalty_cost::Float



913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
# File 'proto_docs/google/cloud/optimization/v1/fleet_routing.rb', line 913

class Shipment
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Request for a visit which can be done by a vehicle: it has a geo-location
  # (or two, see below), opening and closing times represented by time windows,
  # and a service duration time (time spent by the vehicle once it has arrived
  # to pickup or drop off goods).
  # @!attribute [rw] arrival_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_location` must not be specified.
  # @!attribute [rw] arrival_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_waypoint` must not be specified.
  # @!attribute [rw] departure_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_location`.
  #     If the shipment model has duration distance matrices,
  #     `departure_location` must not be specified.
  # @!attribute [rw] departure_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_waypoint`.
  #     If the shipment model has duration distance matrices,
  #     `departure_waypoint` must not be specified.
  # @!attribute [rw] tags
  #   @return [::Array<::String>]
  #     Specifies tags attached to the visit request.
  #     Empty or duplicate strings are not allowed.
  # @!attribute [rw] time_windows
  #   @return [::Array<::Google::Cloud::Optimization::V1::TimeWindow>]
  #     Time windows which constrain the arrival time at a visit.
  #     Note that a vehicle may depart outside of the arrival time window, i.e.
  #     arrival time + duration do not need to be inside a time window. This can
  #     result in waiting time if the vehicle arrives before
  #     {::Google::Cloud::Optimization::V1::TimeWindow#start_time TimeWindow.start_time}.
  #
  #     The absence of `TimeWindow` means that the vehicle can perform this visit
  #     at any time.
  #
  #     Time windows must be disjoint, i.e. no time window must overlap with or
  #     be adjacent to another, and they must be in increasing order.
  #
  #     `cost_per_hour_after_soft_end_time` and `soft_end_time` can only
  #     be set if there is a single time window.
  # @!attribute [rw] duration
  #   @return [::Google::Protobuf::Duration]
  #     Duration of the visit, i.e. time spent by the vehicle between arrival
  #     and departure (to be added to the possible waiting time; see
  #     `time_windows`).
  # @!attribute [rw] cost
  #   @return [::Float]
  #     Cost to service this visit request on a vehicle route. This can be used
  #     to pay different costs for each alternative pickup or delivery of a
  #     shipment. This cost must be in the same unit as `Shipment.penalty_cost`
  #     and must not be negative.
  # @!attribute [rw] load_demands
  #   @return [::Google::Protobuf::Map{::String => ::Google::Cloud::Optimization::V1::Shipment::Load}]
  #     Load demands of this visit request. This is just like
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}
  #     field, except that it only applies to this
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest VisitRequest}
  #     instead of the whole {::Google::Cloud::Optimization::V1::Shipment Shipment}.
  #     The demands listed here are added to the demands listed in
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}.
  # @!attribute [rw] visit_types
  #   @return [::Array<::String>]
  #     Specifies the types of the visit. This may be used to allocate additional
  #     time required for a vehicle to complete this visit (see
  #     {::Google::Cloud::Optimization::V1::Vehicle#extra_visit_duration_for_visit_type Vehicle.extra_visit_duration_for_visit_type}).
  #
  #     A type can only appear once.
  # @!attribute [rw] label
  #   @return [::String]
  #     Specifies a label for this `VisitRequest`. This label is reported in the
  #     response as `visit_label` in the corresponding
  #     {::Google::Cloud::Optimization::V1::ShipmentRoute::Visit ShipmentRoute.Visit}.
  # @!attribute [rw] demands
  #   @deprecated This field is deprecated and may be removed in the next major version update.
  #   @return [::Array<::Google::Cloud::Optimization::V1::CapacityQuantity>]
  #     Deprecated: Use
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest#load_demands VisitRequest.load_demands}
  #     instead.
  class VisitRequest
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # @!attribute [rw] key
    #   @return [::String]
    # @!attribute [rw] value
    #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
    class LoadDemandsEntry
      include ::Google::Protobuf::MessageExts
      extend ::Google::Protobuf::MessageExts::ClassMethods
    end
  end

  # When performing a visit, a predefined amount may be added to the vehicle
  # load if it's a pickup, or subtracted if it's a delivery. This message
  # defines such amount. See
  # {::Google::Cloud::Optimization::V1::Shipment#load_demands load_demands}.
  # @!attribute [rw] amount
  #   @return [::Integer]
  #     The amount by which the load of the vehicle performing the corresponding
  #     visit will vary. Since it is an integer, users are advised to choose an
  #     appropriate unit to avoid loss of precision. Must be ≥ 0.
  class Load
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
  class LoadDemandsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#pickup_to_delivery_absolute_detour_limit::Google::Protobuf::Duration



913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
# File 'proto_docs/google/cloud/optimization/v1/fleet_routing.rb', line 913

class Shipment
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Request for a visit which can be done by a vehicle: it has a geo-location
  # (or two, see below), opening and closing times represented by time windows,
  # and a service duration time (time spent by the vehicle once it has arrived
  # to pickup or drop off goods).
  # @!attribute [rw] arrival_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_location` must not be specified.
  # @!attribute [rw] arrival_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_waypoint` must not be specified.
  # @!attribute [rw] departure_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_location`.
  #     If the shipment model has duration distance matrices,
  #     `departure_location` must not be specified.
  # @!attribute [rw] departure_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_waypoint`.
  #     If the shipment model has duration distance matrices,
  #     `departure_waypoint` must not be specified.
  # @!attribute [rw] tags
  #   @return [::Array<::String>]
  #     Specifies tags attached to the visit request.
  #     Empty or duplicate strings are not allowed.
  # @!attribute [rw] time_windows
  #   @return [::Array<::Google::Cloud::Optimization::V1::TimeWindow>]
  #     Time windows which constrain the arrival time at a visit.
  #     Note that a vehicle may depart outside of the arrival time window, i.e.
  #     arrival time + duration do not need to be inside a time window. This can
  #     result in waiting time if the vehicle arrives before
  #     {::Google::Cloud::Optimization::V1::TimeWindow#start_time TimeWindow.start_time}.
  #
  #     The absence of `TimeWindow` means that the vehicle can perform this visit
  #     at any time.
  #
  #     Time windows must be disjoint, i.e. no time window must overlap with or
  #     be adjacent to another, and they must be in increasing order.
  #
  #     `cost_per_hour_after_soft_end_time` and `soft_end_time` can only
  #     be set if there is a single time window.
  # @!attribute [rw] duration
  #   @return [::Google::Protobuf::Duration]
  #     Duration of the visit, i.e. time spent by the vehicle between arrival
  #     and departure (to be added to the possible waiting time; see
  #     `time_windows`).
  # @!attribute [rw] cost
  #   @return [::Float]
  #     Cost to service this visit request on a vehicle route. This can be used
  #     to pay different costs for each alternative pickup or delivery of a
  #     shipment. This cost must be in the same unit as `Shipment.penalty_cost`
  #     and must not be negative.
  # @!attribute [rw] load_demands
  #   @return [::Google::Protobuf::Map{::String => ::Google::Cloud::Optimization::V1::Shipment::Load}]
  #     Load demands of this visit request. This is just like
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}
  #     field, except that it only applies to this
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest VisitRequest}
  #     instead of the whole {::Google::Cloud::Optimization::V1::Shipment Shipment}.
  #     The demands listed here are added to the demands listed in
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}.
  # @!attribute [rw] visit_types
  #   @return [::Array<::String>]
  #     Specifies the types of the visit. This may be used to allocate additional
  #     time required for a vehicle to complete this visit (see
  #     {::Google::Cloud::Optimization::V1::Vehicle#extra_visit_duration_for_visit_type Vehicle.extra_visit_duration_for_visit_type}).
  #
  #     A type can only appear once.
  # @!attribute [rw] label
  #   @return [::String]
  #     Specifies a label for this `VisitRequest`. This label is reported in the
  #     response as `visit_label` in the corresponding
  #     {::Google::Cloud::Optimization::V1::ShipmentRoute::Visit ShipmentRoute.Visit}.
  # @!attribute [rw] demands
  #   @deprecated This field is deprecated and may be removed in the next major version update.
  #   @return [::Array<::Google::Cloud::Optimization::V1::CapacityQuantity>]
  #     Deprecated: Use
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest#load_demands VisitRequest.load_demands}
  #     instead.
  class VisitRequest
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # @!attribute [rw] key
    #   @return [::String]
    # @!attribute [rw] value
    #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
    class LoadDemandsEntry
      include ::Google::Protobuf::MessageExts
      extend ::Google::Protobuf::MessageExts::ClassMethods
    end
  end

  # When performing a visit, a predefined amount may be added to the vehicle
  # load if it's a pickup, or subtracted if it's a delivery. This message
  # defines such amount. See
  # {::Google::Cloud::Optimization::V1::Shipment#load_demands load_demands}.
  # @!attribute [rw] amount
  #   @return [::Integer]
  #     The amount by which the load of the vehicle performing the corresponding
  #     visit will vary. Since it is an integer, users are advised to choose an
  #     appropriate unit to avoid loss of precision. Must be ≥ 0.
  class Load
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
  class LoadDemandsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#pickup_to_delivery_relative_detour_limit::Float



913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
# File 'proto_docs/google/cloud/optimization/v1/fleet_routing.rb', line 913

class Shipment
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Request for a visit which can be done by a vehicle: it has a geo-location
  # (or two, see below), opening and closing times represented by time windows,
  # and a service duration time (time spent by the vehicle once it has arrived
  # to pickup or drop off goods).
  # @!attribute [rw] arrival_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_location` must not be specified.
  # @!attribute [rw] arrival_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_waypoint` must not be specified.
  # @!attribute [rw] departure_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_location`.
  #     If the shipment model has duration distance matrices,
  #     `departure_location` must not be specified.
  # @!attribute [rw] departure_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_waypoint`.
  #     If the shipment model has duration distance matrices,
  #     `departure_waypoint` must not be specified.
  # @!attribute [rw] tags
  #   @return [::Array<::String>]
  #     Specifies tags attached to the visit request.
  #     Empty or duplicate strings are not allowed.
  # @!attribute [rw] time_windows
  #   @return [::Array<::Google::Cloud::Optimization::V1::TimeWindow>]
  #     Time windows which constrain the arrival time at a visit.
  #     Note that a vehicle may depart outside of the arrival time window, i.e.
  #     arrival time + duration do not need to be inside a time window. This can
  #     result in waiting time if the vehicle arrives before
  #     {::Google::Cloud::Optimization::V1::TimeWindow#start_time TimeWindow.start_time}.
  #
  #     The absence of `TimeWindow` means that the vehicle can perform this visit
  #     at any time.
  #
  #     Time windows must be disjoint, i.e. no time window must overlap with or
  #     be adjacent to another, and they must be in increasing order.
  #
  #     `cost_per_hour_after_soft_end_time` and `soft_end_time` can only
  #     be set if there is a single time window.
  # @!attribute [rw] duration
  #   @return [::Google::Protobuf::Duration]
  #     Duration of the visit, i.e. time spent by the vehicle between arrival
  #     and departure (to be added to the possible waiting time; see
  #     `time_windows`).
  # @!attribute [rw] cost
  #   @return [::Float]
  #     Cost to service this visit request on a vehicle route. This can be used
  #     to pay different costs for each alternative pickup or delivery of a
  #     shipment. This cost must be in the same unit as `Shipment.penalty_cost`
  #     and must not be negative.
  # @!attribute [rw] load_demands
  #   @return [::Google::Protobuf::Map{::String => ::Google::Cloud::Optimization::V1::Shipment::Load}]
  #     Load demands of this visit request. This is just like
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}
  #     field, except that it only applies to this
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest VisitRequest}
  #     instead of the whole {::Google::Cloud::Optimization::V1::Shipment Shipment}.
  #     The demands listed here are added to the demands listed in
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}.
  # @!attribute [rw] visit_types
  #   @return [::Array<::String>]
  #     Specifies the types of the visit. This may be used to allocate additional
  #     time required for a vehicle to complete this visit (see
  #     {::Google::Cloud::Optimization::V1::Vehicle#extra_visit_duration_for_visit_type Vehicle.extra_visit_duration_for_visit_type}).
  #
  #     A type can only appear once.
  # @!attribute [rw] label
  #   @return [::String]
  #     Specifies a label for this `VisitRequest`. This label is reported in the
  #     response as `visit_label` in the corresponding
  #     {::Google::Cloud::Optimization::V1::ShipmentRoute::Visit ShipmentRoute.Visit}.
  # @!attribute [rw] demands
  #   @deprecated This field is deprecated and may be removed in the next major version update.
  #   @return [::Array<::Google::Cloud::Optimization::V1::CapacityQuantity>]
  #     Deprecated: Use
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest#load_demands VisitRequest.load_demands}
  #     instead.
  class VisitRequest
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # @!attribute [rw] key
    #   @return [::String]
    # @!attribute [rw] value
    #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
    class LoadDemandsEntry
      include ::Google::Protobuf::MessageExts
      extend ::Google::Protobuf::MessageExts::ClassMethods
    end
  end

  # When performing a visit, a predefined amount may be added to the vehicle
  # load if it's a pickup, or subtracted if it's a delivery. This message
  # defines such amount. See
  # {::Google::Cloud::Optimization::V1::Shipment#load_demands load_demands}.
  # @!attribute [rw] amount
  #   @return [::Integer]
  #     The amount by which the load of the vehicle performing the corresponding
  #     visit will vary. Since it is an integer, users are advised to choose an
  #     appropriate unit to avoid loss of precision. Must be ≥ 0.
  class Load
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
  class LoadDemandsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#pickup_to_delivery_time_limit::Google::Protobuf::Duration



913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
# File 'proto_docs/google/cloud/optimization/v1/fleet_routing.rb', line 913

class Shipment
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Request for a visit which can be done by a vehicle: it has a geo-location
  # (or two, see below), opening and closing times represented by time windows,
  # and a service duration time (time spent by the vehicle once it has arrived
  # to pickup or drop off goods).
  # @!attribute [rw] arrival_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_location` must not be specified.
  # @!attribute [rw] arrival_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_waypoint` must not be specified.
  # @!attribute [rw] departure_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_location`.
  #     If the shipment model has duration distance matrices,
  #     `departure_location` must not be specified.
  # @!attribute [rw] departure_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_waypoint`.
  #     If the shipment model has duration distance matrices,
  #     `departure_waypoint` must not be specified.
  # @!attribute [rw] tags
  #   @return [::Array<::String>]
  #     Specifies tags attached to the visit request.
  #     Empty or duplicate strings are not allowed.
  # @!attribute [rw] time_windows
  #   @return [::Array<::Google::Cloud::Optimization::V1::TimeWindow>]
  #     Time windows which constrain the arrival time at a visit.
  #     Note that a vehicle may depart outside of the arrival time window, i.e.
  #     arrival time + duration do not need to be inside a time window. This can
  #     result in waiting time if the vehicle arrives before
  #     {::Google::Cloud::Optimization::V1::TimeWindow#start_time TimeWindow.start_time}.
  #
  #     The absence of `TimeWindow` means that the vehicle can perform this visit
  #     at any time.
  #
  #     Time windows must be disjoint, i.e. no time window must overlap with or
  #     be adjacent to another, and they must be in increasing order.
  #
  #     `cost_per_hour_after_soft_end_time` and `soft_end_time` can only
  #     be set if there is a single time window.
  # @!attribute [rw] duration
  #   @return [::Google::Protobuf::Duration]
  #     Duration of the visit, i.e. time spent by the vehicle between arrival
  #     and departure (to be added to the possible waiting time; see
  #     `time_windows`).
  # @!attribute [rw] cost
  #   @return [::Float]
  #     Cost to service this visit request on a vehicle route. This can be used
  #     to pay different costs for each alternative pickup or delivery of a
  #     shipment. This cost must be in the same unit as `Shipment.penalty_cost`
  #     and must not be negative.
  # @!attribute [rw] load_demands
  #   @return [::Google::Protobuf::Map{::String => ::Google::Cloud::Optimization::V1::Shipment::Load}]
  #     Load demands of this visit request. This is just like
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}
  #     field, except that it only applies to this
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest VisitRequest}
  #     instead of the whole {::Google::Cloud::Optimization::V1::Shipment Shipment}.
  #     The demands listed here are added to the demands listed in
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}.
  # @!attribute [rw] visit_types
  #   @return [::Array<::String>]
  #     Specifies the types of the visit. This may be used to allocate additional
  #     time required for a vehicle to complete this visit (see
  #     {::Google::Cloud::Optimization::V1::Vehicle#extra_visit_duration_for_visit_type Vehicle.extra_visit_duration_for_visit_type}).
  #
  #     A type can only appear once.
  # @!attribute [rw] label
  #   @return [::String]
  #     Specifies a label for this `VisitRequest`. This label is reported in the
  #     response as `visit_label` in the corresponding
  #     {::Google::Cloud::Optimization::V1::ShipmentRoute::Visit ShipmentRoute.Visit}.
  # @!attribute [rw] demands
  #   @deprecated This field is deprecated and may be removed in the next major version update.
  #   @return [::Array<::Google::Cloud::Optimization::V1::CapacityQuantity>]
  #     Deprecated: Use
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest#load_demands VisitRequest.load_demands}
  #     instead.
  class VisitRequest
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # @!attribute [rw] key
    #   @return [::String]
    # @!attribute [rw] value
    #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
    class LoadDemandsEntry
      include ::Google::Protobuf::MessageExts
      extend ::Google::Protobuf::MessageExts::ClassMethods
    end
  end

  # When performing a visit, a predefined amount may be added to the vehicle
  # load if it's a pickup, or subtracted if it's a delivery. This message
  # defines such amount. See
  # {::Google::Cloud::Optimization::V1::Shipment#load_demands load_demands}.
  # @!attribute [rw] amount
  #   @return [::Integer]
  #     The amount by which the load of the vehicle performing the corresponding
  #     visit will vary. Since it is an integer, users are advised to choose an
  #     appropriate unit to avoid loss of precision. Must be ≥ 0.
  class Load
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
  class LoadDemandsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#pickups::Array<::Google::Cloud::Optimization::V1::Shipment::VisitRequest>



913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
# File 'proto_docs/google/cloud/optimization/v1/fleet_routing.rb', line 913

class Shipment
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Request for a visit which can be done by a vehicle: it has a geo-location
  # (or two, see below), opening and closing times represented by time windows,
  # and a service duration time (time spent by the vehicle once it has arrived
  # to pickup or drop off goods).
  # @!attribute [rw] arrival_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_location` must not be specified.
  # @!attribute [rw] arrival_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_waypoint` must not be specified.
  # @!attribute [rw] departure_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_location`.
  #     If the shipment model has duration distance matrices,
  #     `departure_location` must not be specified.
  # @!attribute [rw] departure_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_waypoint`.
  #     If the shipment model has duration distance matrices,
  #     `departure_waypoint` must not be specified.
  # @!attribute [rw] tags
  #   @return [::Array<::String>]
  #     Specifies tags attached to the visit request.
  #     Empty or duplicate strings are not allowed.
  # @!attribute [rw] time_windows
  #   @return [::Array<::Google::Cloud::Optimization::V1::TimeWindow>]
  #     Time windows which constrain the arrival time at a visit.
  #     Note that a vehicle may depart outside of the arrival time window, i.e.
  #     arrival time + duration do not need to be inside a time window. This can
  #     result in waiting time if the vehicle arrives before
  #     {::Google::Cloud::Optimization::V1::TimeWindow#start_time TimeWindow.start_time}.
  #
  #     The absence of `TimeWindow` means that the vehicle can perform this visit
  #     at any time.
  #
  #     Time windows must be disjoint, i.e. no time window must overlap with or
  #     be adjacent to another, and they must be in increasing order.
  #
  #     `cost_per_hour_after_soft_end_time` and `soft_end_time` can only
  #     be set if there is a single time window.
  # @!attribute [rw] duration
  #   @return [::Google::Protobuf::Duration]
  #     Duration of the visit, i.e. time spent by the vehicle between arrival
  #     and departure (to be added to the possible waiting time; see
  #     `time_windows`).
  # @!attribute [rw] cost
  #   @return [::Float]
  #     Cost to service this visit request on a vehicle route. This can be used
  #     to pay different costs for each alternative pickup or delivery of a
  #     shipment. This cost must be in the same unit as `Shipment.penalty_cost`
  #     and must not be negative.
  # @!attribute [rw] load_demands
  #   @return [::Google::Protobuf::Map{::String => ::Google::Cloud::Optimization::V1::Shipment::Load}]
  #     Load demands of this visit request. This is just like
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}
  #     field, except that it only applies to this
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest VisitRequest}
  #     instead of the whole {::Google::Cloud::Optimization::V1::Shipment Shipment}.
  #     The demands listed here are added to the demands listed in
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}.
  # @!attribute [rw] visit_types
  #   @return [::Array<::String>]
  #     Specifies the types of the visit. This may be used to allocate additional
  #     time required for a vehicle to complete this visit (see
  #     {::Google::Cloud::Optimization::V1::Vehicle#extra_visit_duration_for_visit_type Vehicle.extra_visit_duration_for_visit_type}).
  #
  #     A type can only appear once.
  # @!attribute [rw] label
  #   @return [::String]
  #     Specifies a label for this `VisitRequest`. This label is reported in the
  #     response as `visit_label` in the corresponding
  #     {::Google::Cloud::Optimization::V1::ShipmentRoute::Visit ShipmentRoute.Visit}.
  # @!attribute [rw] demands
  #   @deprecated This field is deprecated and may be removed in the next major version update.
  #   @return [::Array<::Google::Cloud::Optimization::V1::CapacityQuantity>]
  #     Deprecated: Use
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest#load_demands VisitRequest.load_demands}
  #     instead.
  class VisitRequest
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # @!attribute [rw] key
    #   @return [::String]
    # @!attribute [rw] value
    #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
    class LoadDemandsEntry
      include ::Google::Protobuf::MessageExts
      extend ::Google::Protobuf::MessageExts::ClassMethods
    end
  end

  # When performing a visit, a predefined amount may be added to the vehicle
  # load if it's a pickup, or subtracted if it's a delivery. This message
  # defines such amount. See
  # {::Google::Cloud::Optimization::V1::Shipment#load_demands load_demands}.
  # @!attribute [rw] amount
  #   @return [::Integer]
  #     The amount by which the load of the vehicle performing the corresponding
  #     visit will vary. Since it is an integer, users are advised to choose an
  #     appropriate unit to avoid loss of precision. Must be ≥ 0.
  class Load
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
  class LoadDemandsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end

#shipment_type::String



913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
# File 'proto_docs/google/cloud/optimization/v1/fleet_routing.rb', line 913

class Shipment
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Request for a visit which can be done by a vehicle: it has a geo-location
  # (or two, see below), opening and closing times represented by time windows,
  # and a service duration time (time spent by the vehicle once it has arrived
  # to pickup or drop off goods).
  # @!attribute [rw] arrival_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_location` must not be specified.
  # @!attribute [rw] arrival_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle arrives when performing this
  #     `VisitRequest`. If the shipment model has duration distance matrices,
  #     `arrival_waypoint` must not be specified.
  # @!attribute [rw] departure_location
  #   @return [::Google::Type::LatLng]
  #     The geo-location where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_location`.
  #     If the shipment model has duration distance matrices,
  #     `departure_location` must not be specified.
  # @!attribute [rw] departure_waypoint
  #   @return [::Google::Cloud::Optimization::V1::Waypoint]
  #     The waypoint where the vehicle departs after completing this
  #     `VisitRequest`. Can be omitted if it is the same as `arrival_waypoint`.
  #     If the shipment model has duration distance matrices,
  #     `departure_waypoint` must not be specified.
  # @!attribute [rw] tags
  #   @return [::Array<::String>]
  #     Specifies tags attached to the visit request.
  #     Empty or duplicate strings are not allowed.
  # @!attribute [rw] time_windows
  #   @return [::Array<::Google::Cloud::Optimization::V1::TimeWindow>]
  #     Time windows which constrain the arrival time at a visit.
  #     Note that a vehicle may depart outside of the arrival time window, i.e.
  #     arrival time + duration do not need to be inside a time window. This can
  #     result in waiting time if the vehicle arrives before
  #     {::Google::Cloud::Optimization::V1::TimeWindow#start_time TimeWindow.start_time}.
  #
  #     The absence of `TimeWindow` means that the vehicle can perform this visit
  #     at any time.
  #
  #     Time windows must be disjoint, i.e. no time window must overlap with or
  #     be adjacent to another, and they must be in increasing order.
  #
  #     `cost_per_hour_after_soft_end_time` and `soft_end_time` can only
  #     be set if there is a single time window.
  # @!attribute [rw] duration
  #   @return [::Google::Protobuf::Duration]
  #     Duration of the visit, i.e. time spent by the vehicle between arrival
  #     and departure (to be added to the possible waiting time; see
  #     `time_windows`).
  # @!attribute [rw] cost
  #   @return [::Float]
  #     Cost to service this visit request on a vehicle route. This can be used
  #     to pay different costs for each alternative pickup or delivery of a
  #     shipment. This cost must be in the same unit as `Shipment.penalty_cost`
  #     and must not be negative.
  # @!attribute [rw] load_demands
  #   @return [::Google::Protobuf::Map{::String => ::Google::Cloud::Optimization::V1::Shipment::Load}]
  #     Load demands of this visit request. This is just like
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}
  #     field, except that it only applies to this
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest VisitRequest}
  #     instead of the whole {::Google::Cloud::Optimization::V1::Shipment Shipment}.
  #     The demands listed here are added to the demands listed in
  #     {::Google::Cloud::Optimization::V1::Shipment#load_demands Shipment.load_demands}.
  # @!attribute [rw] visit_types
  #   @return [::Array<::String>]
  #     Specifies the types of the visit. This may be used to allocate additional
  #     time required for a vehicle to complete this visit (see
  #     {::Google::Cloud::Optimization::V1::Vehicle#extra_visit_duration_for_visit_type Vehicle.extra_visit_duration_for_visit_type}).
  #
  #     A type can only appear once.
  # @!attribute [rw] label
  #   @return [::String]
  #     Specifies a label for this `VisitRequest`. This label is reported in the
  #     response as `visit_label` in the corresponding
  #     {::Google::Cloud::Optimization::V1::ShipmentRoute::Visit ShipmentRoute.Visit}.
  # @!attribute [rw] demands
  #   @deprecated This field is deprecated and may be removed in the next major version update.
  #   @return [::Array<::Google::Cloud::Optimization::V1::CapacityQuantity>]
  #     Deprecated: Use
  #     {::Google::Cloud::Optimization::V1::Shipment::VisitRequest#load_demands VisitRequest.load_demands}
  #     instead.
  class VisitRequest
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # @!attribute [rw] key
    #   @return [::String]
    # @!attribute [rw] value
    #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
    class LoadDemandsEntry
      include ::Google::Protobuf::MessageExts
      extend ::Google::Protobuf::MessageExts::ClassMethods
    end
  end

  # When performing a visit, a predefined amount may be added to the vehicle
  # load if it's a pickup, or subtracted if it's a delivery. This message
  # defines such amount. See
  # {::Google::Cloud::Optimization::V1::Shipment#load_demands load_demands}.
  # @!attribute [rw] amount
  #   @return [::Integer]
  #     The amount by which the load of the vehicle performing the corresponding
  #     visit will vary. Since it is an integer, users are advised to choose an
  #     appropriate unit to avoid loss of precision. Must be ≥ 0.
  class Load
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # @!attribute [rw] key
  #   @return [::String]
  # @!attribute [rw] value
  #   @return [::Google::Cloud::Optimization::V1::Shipment::Load]
  class LoadDemandsEntry
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end