Show / Hide Table of Contents

Class Task

A Task in the Delivery API represents a single action to track. In general, there is a distinction between shipment-related Tasks and break Tasks. A shipment can have multiple Tasks associated with it. For example, there could be one Task for the pickup, and one for the drop-off or transfer. Also, different Tasks for a given shipment can be handled by different vehicles. For example, one vehicle could handle the pickup, driving the shipment to the hub, while another vehicle drives the same shipment from the hub to the drop-off location.

Note: gRPC and REST APIs use different field naming conventions. For example, the Task.journey_sharing_info field in the gRPC API and the Task.journeySharingInfo field in the REST API refer to the same field.

Inheritance
object
Task
Implements
IMessage<Task>
IEquatable<Task>
IDeepCloneable<Task>
IBufferMessage
IMessage
Inherited Members
object.GetHashCode()
object.GetType()
object.ToString()
Namespace: Google.Maps.FleetEngine.Delivery.V1
Assembly: Google.Maps.FleetEngine.Delivery.V1.dll
Syntax
public sealed class Task : IMessage<Task>, IEquatable<Task>, IDeepCloneable<Task>, IBufferMessage, IMessage

Constructors

Task()

Declaration
public Task()

Task(Task)

Declaration
public Task(Task other)
Parameters
Type Name Description
Task other

Properties

Attributes

A list of custom Task attributes. Each attribute must have a unique key.

Declaration
public RepeatedField<TaskAttribute> Attributes { get; }
Property Value
Type Description
RepeatedField<TaskAttribute>

DeliveryVehicleId

Output only. The ID of the vehicle that is executing this Task. Delivery Vehicle IDs are subject to the following restrictions:

  • Must be a valid Unicode string.
  • Limited to a maximum length of 64 characters.
  • Normalized according to [Unicode Normalization Form C] (http://www.unicode.org/reports/tr15/).
  • May not contain any of the following ASCII characters: '/', ':', '?', ',', or '#'.
Declaration
public string DeliveryVehicleId { get; set; }
Property Value
Type Description
string

JourneySharingInfo

Output only. Journey sharing-specific fields. Not populated when state is CLOSED.

Declaration
public Task.Types.JourneySharingInfo JourneySharingInfo { get; set; }
Property Value
Type Description
Task.Types.JourneySharingInfo

Name

Must be in the format providers/{provider}/tasks/{task}.

Declaration
public string Name { get; set; }
Property Value
Type Description
string

PlannedLocation

Immutable. The location where the Task will be completed. Optional for UNAVAILABLE Tasks, but required for all other Tasks.

Declaration
public LocationInfo PlannedLocation { get; set; }
Property Value
Type Description
LocationInfo

State

Required. The current execution state of the Task.

Declaration
public Task.Types.State State { get; set; }
Property Value
Type Description
Task.Types.State

TargetTimeWindow

The time window during which the task should be completed.

Declaration
public TimeWindow TargetTimeWindow { get; set; }
Property Value
Type Description
TimeWindow

TaskDuration

Required. Immutable. The time needed to execute a Task at this location.

Declaration
public Duration TaskDuration { get; set; }
Property Value
Type Description
Duration

TaskName

TaskName-typed view over the Name resource name property.

Declaration
public TaskName TaskName { get; set; }
Property Value
Type Description
TaskName

TaskOutcome

The outcome of the Task.

Declaration
public Task.Types.TaskOutcome TaskOutcome { get; set; }
Property Value
Type Description
Task.Types.TaskOutcome

TaskOutcomeLocation

The location where the Task's outcome was set. This value is updated as part of UpdateTask. If this value isn't explicitly updated by the provider, then Fleet Engine populates it by default with the last known vehicle location (the raw location).

Declaration
public LocationInfo TaskOutcomeLocation { get; set; }
Property Value
Type Description
LocationInfo

TaskOutcomeLocationSource

Indicates where the value of the task_outcome_location came from.

Declaration
public Task.Types.TaskOutcomeLocationSource TaskOutcomeLocationSource { get; set; }
Property Value
Type Description
Task.Types.TaskOutcomeLocationSource

TaskOutcomeTime

The timestamp that indicates when the Task's outcome was set by the provider.

Declaration
public Timestamp TaskOutcomeTime { get; set; }
Property Value
Type Description
Timestamp

TaskTrackingViewConfig

The configuration for task tracking that specifies which data elements are visible to the end users under what circumstances.

Declaration
public TaskTrackingViewConfig TaskTrackingViewConfig { get; set; }
Property Value
Type Description
TaskTrackingViewConfig

TrackingId

Immutable. This field facilitates the storing of an ID so you can avoid using a complicated mapping. You cannot set tracking_id for Tasks of type UNAVAILABLE and SCHEDULED_STOP. These IDs are subject to the following restrictions:

  • Must be a valid Unicode string.
  • Limited to a maximum length of 64 characters.
  • Normalized according to [Unicode Normalization Form C] (http://www.unicode.org/reports/tr15/).
  • May not contain any of the following ASCII characters: '/', ':', '?', ',', or '#'.
Declaration
public string TrackingId { get; set; }
Property Value
Type Description
string

Type

Required. Immutable. Defines the type of the Task. For example, a break or shipment.

Declaration
public Task.Types.Type Type { get; set; }
Property Value
Type Description
Task.Types.Type
In this article
Back to top Generated by DocFX