/**
 * <p class=proto-main>This API is to push some destinations to the vehicle, the SDP shall send the destinations data to the TBM when the TBM is connected.
 * TBM will save the destination.
 * </p>
 *
 * <div class=proto-hier>
 * 	 UconnectAny
 * 	   |
 * 	   |---- <a href="#com.fca.uconnect.global.DestinationPush">DestinationPush destinationPush (240)</a>
 * 	   |
 * 	   |---- <a href="#com.fca.uconnect.global.DestinationPushResponse">DestinationPushResponse destinationPushResponse (241)</a>
 *
 * </div>
 *
 *  <h3 class=change-log-hdr> Change Log</h3>
 *  <table id="change-log" class="change-log"><thead><tr>
 *	<td>Version</td><td>Date</td><td>Notes</td></tr></thead>
 *   <tbody>
*  <tr><td>1.6</td><td>2019-07-25</td><td>Updated Sequence Diagram per V2C-037</td></tr>
*  <tr><td>1.5</td><td>2018-06-01</td><td>Added ServiceRequestID, removed Repeated from Destination field </td></tr>
* <tr><td>1.4</td><td>2018-05-29</td><td>Added POI and Address per Assembla 455 </td></tr>
 *    <tr><td>1.3</td><td>2017-11-2</td><td>Update to Proto3</td></tr>
 * 	 <tr><td>1.2</td><td>2017-09-27</td><td>Update DestinationPushResponse.</td></tr>
 * 	 <tr><td>1.1</td><td>2017-04-12</td><td>Added DestinationPushResponse and removed MAPDBVariant.</td></tr>
 *	 <tr><td>1.0</td><td>2017-03-19</td><td>Release of initial Proto.</td></tr>
 *	</tbody></table>
 *
 *  <h3 class=change-log-hdr>List of MQTT Topics</h3>
 *  <table class="change-log"><thead><tr>
 *	<td>Flow</td><td>Type</td><td>Topic Name</td></tr></thead>
 *    <tbody>
 *   <tr><td>Cloud send to Vehicle</td><td>Publish</td><td>fcasdp/${iot:ClientId}/SDTC</td></tr>
 *	 <tr><td>Cloud receive from Vehicle</td><td>Subscribe</td><td>fcasdp/SDTC/#</td></tr>
 *	 <tr><td>Vehicle send to Cloud </td><td>Publish</td><td>fcasdp/SDTC/${iot:ClientId}</td></tr>
 *	 <tr><td>Vehicle receive from Cloud </td><td>Subscribe</td><td>fcasdp/${iot:ClientId}/#</td></tr>
 *	</tbody></table>
 * <h3 class=change-log-hdr>Data Flow</h3>
 * <p>The following sequence diagram depicts the flow of messages between the HU and the SDP:</p>
 *
 * <img class=img-border src=./images/senddesttoveh.png>
 *
 * <table class=sequence-table><thead><tr>
 *	<td>Seq</td><td>Title</td><td>Role</td><td>Message</td><td>Topic</td><td>Description</td></tr></thead>
 *   <tbody>
 * <tr><td>1.</td><td>Send Destination to Vehicle Event</td><td>SDP</td><td></td><td></td><td><p>The SDP triggers SendDestinationToCar event which triggers DestinationPush to the Client.</p></td></tr>
 * <tr><td>2.</td><td>Assign MessageId</td><td>SDP</td><td></td><td></td><td><p>The SDP generates the messageId for the message by incrementing a sequence counter.</p></td></tr>
 * <tr><td>3.</td><td>Send DestinationPush Message</td><td>SDP</td><td>DestinationPush</td><td>${iot:ClientId}/SDTC</td><td><p>The SDP populates the DestinationPush Message with the required elements and publishes to the SendDestinationToCar topic.</p></td></tr>
 * <tr><td>4.</td><td>Process Message</td><td>HU</td><td></td><td></td><td><p>The HU processes the message and generates an DestinationPushResponse Message with the status and the correlationId set to the messageId from the received DestinationPush Message.</p></td></tr>
 * <tr><td>5.</td><td>Send DestinationPushResponse Message</td><td>HU</td><td>DestinationPushResponse</td><td>/SDTC/${iot:ClientId}</td><td><p>The TBM publishes the response message to the SendDestinationToCar topic for the SDP to receive.</p></td></tr>
 * <tr><td>6.</td><td>Process Message</td><td>SDP</td><td></td><td></td><td><p>The SDP receives the message and verifies the correlationId matches the messageId of the sent request.</p></td></tr>
 * </tbody>
 * </table>
 */
 syntax="proto3";
 
package com.fca.uconnect.global;
//import public "Global_Uconnect_Control.proto";
import public "Global_Uconnect_VehicleInfo.proto";
/**
 * This message represents  list of Destinations that User Can push to the Vehicle.
 * <div class=exmsg-main>
 * <h4>DestinationPush Example Message:</h4>
 * <div class=ex-msg>
 *	<code>
 *		timestamp: 1490014360254
 * 		messageId: 11
 * 		messages
 * 		{
 * 		 [com.fca.uconnect.global.destinationPush]
 * 		 {
 * 		  isImmediateNavigation: false
 * 		 destinationList
 * 		 {
 * 		  destinationLocation
 * 		  {
 * 		   longitude: -83.671875
 * 		   latitude: 42.4802
 * 		  }
 * 		  poi
 * 		  {
 * 		   name: "ABCD Restaurant"
 * 		   category: "Restaurant"
 * 		   id: 123
 * 		   phoneNumber: "123 456 7890"
 * 		  description: "favorite"
 * 		  url: "www.abcrestaurant.com"
 * 		 }
 * 		address
 * 		{
 * 		 houseNbr: "1000"
 * 		 streetName: "Chrystler Drive"
 * 		 cityName: "Auburn Hills"
 * 		 provinceName: "Michigan"
 * 		 countryName: "USA"
 * 		 zipCode: 48326
 * 		}
 * 		timestamp: 1490014360251
 * 		routePreferenceEnum: FAST
 * 	   }
 * 	  }
 * 	 }
 *	</code>
 *   </div>
 * </div>
 */
message DestinationPush {

   // bool isImmediateNavigation = 1;
   Destination destinationList=2;
   bytes LocationID = 3;	/// Service Request ID Added for Trace-ability. Assigned by the SDP. Recommended that Location requests assign the locationID from DB
}
message DestinationPushResponse{
	enum ResponseEnum{
		SUCCESS = 0;
		INVALID_LOCATION = 1;
		INVALID_POI = 2;
		INVALID_ADDRESS = 3;
		INVALID_ROUTE_PREFERENCE = 4;
		ERROR = 5;	/// Generic Error Enumeration from Application Level or System Level Error
	}
	 ResponseEnum response = 1;



	 bool isTransient = 2; /// Indicates if the error is transient and to attempt a retry.
	 int32 failureReasonCode = 3; /// provide detailed errror reason code.
      bytes LocationID = 4;	/// Assigned by the SDP. Recommended that Location requests assign the locationID from DB
}
//extend UconnectAny {
  //   DestinationPush destinationPush = 240;
   //  DestinationPushResponse destinationPushResponse = 241;
// }
