@geoapify/route-planner-sdk
Version:
A TypeScript SDK for the Geoapify Route Planner API that simplifies route optimization requests, and helps visualize and edit resulting routes.
47 lines (46 loc) • 935 B
JavaScript
export class RouteAction {
constructor(raw) {
if (raw) {
this.raw = raw;
}
else {
throw new Error("RouteActionData is undefined");
}
}
getRaw() {
return this.raw;
}
getType() {
return this.raw.type;
}
getStartTime() {
return this.raw.start_time;
}
getDuration() {
return this.raw.duration;
}
getShipmentIndex() {
return this.raw.shipment_index;
}
getShipmentId() {
return this.raw.shipment_id;
}
getLocationIndex() {
return this.raw.location_index;
}
getLocationId() {
return this.raw.location_id;
}
getJobIndex() {
return this.raw.job_index;
}
getJobId() {
return this.raw.job_id;
}
getIndex() {
return this.raw.index;
}
getWaypointIndex() {
return this.raw.waypoint_index;
}
}