@@ -3,9 +3,9 @@ |
||
3 | 3 | |
4 | 4 | class myErrorHandler extends \Exception |
5 | 5 | { |
6 | - public function proc_error($errno, $errstr, $errfile, $errline) |
|
7 | - { |
|
8 | - echo "line: $errline --- ".$errstr."<br>"; |
|
6 | + public function proc_error($errno, $errstr, $errfile, $errline) |
|
7 | + { |
|
8 | + echo "line: $errline --- ".$errstr."<br>"; |
|
9 | 9 | |
10 | - } |
|
10 | + } |
|
11 | 11 | } |
@@ -3,9 +3,9 @@ |
||
3 | 3 | |
4 | 4 | class Metric |
5 | 5 | { |
6 | - const EUCLIDEAN = 1; //measures point to point distance as a straight line |
|
7 | - const MANHATTAN = 2; //measures point to point distance as taxicab geometry line |
|
8 | - const GEODESIC = 3; //measures point to point distance approximating curvature of the earth |
|
9 | - const MATRIX = 4; //measures point to point distance by traversing the actual road network |
|
10 | - const EXACT_2D = 5; //measures point to point distance using 2d rectilinear distance |
|
6 | + const EUCLIDEAN = 1; //measures point to point distance as a straight line |
|
7 | + const MANHATTAN = 2; //measures point to point distance as taxicab geometry line |
|
8 | + const GEODESIC = 3; //measures point to point distance approximating curvature of the earth |
|
9 | + const MATRIX = 4; //measures point to point distance by traversing the actual road network |
|
10 | + const EXACT_2D = 5; //measures point to point distance using 2d rectilinear distance |
|
11 | 11 | } |
@@ -3,34 +3,34 @@ |
||
3 | 3 | |
4 | 4 | class ActivityTypes |
5 | 5 | { |
6 | - const AREA_REMOVED = 'area-removed'; |
|
7 | - const AREA_ADDED = 'area-added'; |
|
8 | - const AREA_UPDATED = 'area-updated'; |
|
9 | - const DELETE_DESTINATION = 'delete-destination'; |
|
10 | - const INSERT_DESTINATION = 'insert-destination'; |
|
11 | - const DESTINATION_OUT_SEQUENCE = 'destination-out-sequence'; |
|
12 | - const DRIVER_ARRIVED_EARLY = 'driver-arrived-early'; |
|
13 | - const DRIVER_ARRIVED_LATE = 'driver-arrived-late'; |
|
14 | - const DRIVER_ARRIVED_ON_TIME = 'driver-arrived-on-time'; |
|
15 | - const GEOFENCE_LEFT = 'geofence-left'; |
|
16 | - const GEOFENCE_ENTERED = 'geofence-entered'; |
|
17 | - const MARK_DESTINATION_DEPARTED = 'mark-destination-departed'; |
|
18 | - const MARK_DESTINATION_VISITED = 'mark-destination-visited'; |
|
19 | - const MEMBER_CREATED = 'member-created'; |
|
20 | - const MEMBER_DELETED = 'member-deleted'; |
|
21 | - const MEMBER_MODIFIED = 'member-modified'; |
|
22 | - const MOVE_DESTINATION = 'move-destination'; |
|
23 | - const NOTE_INSERT = 'note-insert'; |
|
24 | - const ROUTE_DELETE = 'route-delete'; |
|
25 | - const ROUTE_OPTIMIZED = 'route-optimized'; |
|
26 | - const ROUTE_OWNER_CHANGED = 'route-owner-changed'; |
|
27 | - const ROUTE_DUPLICATE = 'route-duplicate'; |
|
28 | - const UPDATE_DESTINATIONS = 'update-destinations'; |
|
29 | - const USER_MESSAGE = 'user_message'; |
|
6 | + const AREA_REMOVED = 'area-removed'; |
|
7 | + const AREA_ADDED = 'area-added'; |
|
8 | + const AREA_UPDATED = 'area-updated'; |
|
9 | + const DELETE_DESTINATION = 'delete-destination'; |
|
10 | + const INSERT_DESTINATION = 'insert-destination'; |
|
11 | + const DESTINATION_OUT_SEQUENCE = 'destination-out-sequence'; |
|
12 | + const DRIVER_ARRIVED_EARLY = 'driver-arrived-early'; |
|
13 | + const DRIVER_ARRIVED_LATE = 'driver-arrived-late'; |
|
14 | + const DRIVER_ARRIVED_ON_TIME = 'driver-arrived-on-time'; |
|
15 | + const GEOFENCE_LEFT = 'geofence-left'; |
|
16 | + const GEOFENCE_ENTERED = 'geofence-entered'; |
|
17 | + const MARK_DESTINATION_DEPARTED = 'mark-destination-departed'; |
|
18 | + const MARK_DESTINATION_VISITED = 'mark-destination-visited'; |
|
19 | + const MEMBER_CREATED = 'member-created'; |
|
20 | + const MEMBER_DELETED = 'member-deleted'; |
|
21 | + const MEMBER_MODIFIED = 'member-modified'; |
|
22 | + const MOVE_DESTINATION = 'move-destination'; |
|
23 | + const NOTE_INSERT = 'note-insert'; |
|
24 | + const ROUTE_DELETE = 'route-delete'; |
|
25 | + const ROUTE_OPTIMIZED = 'route-optimized'; |
|
26 | + const ROUTE_OWNER_CHANGED = 'route-owner-changed'; |
|
27 | + const ROUTE_DUPLICATE = 'route-duplicate'; |
|
28 | + const UPDATE_DESTINATIONS = 'update-destinations'; |
|
29 | + const USER_MESSAGE = 'user_message'; |
|
30 | 30 | |
31 | - static function getConstants() { |
|
32 | - $atc = new \ReflectionClass('Route4Me\\Enum\\ActivityTypes'); |
|
33 | - return $atc->getConstants(); |
|
34 | - } |
|
31 | + static function getConstants() { |
|
32 | + $atc = new \ReflectionClass('Route4Me\\Enum\\ActivityTypes'); |
|
33 | + return $atc->getConstants(); |
|
34 | + } |
|
35 | 35 | } |
36 | 36 |
@@ -3,9 +3,9 @@ |
||
3 | 3 | |
4 | 4 | class TravelMode |
5 | 5 | { |
6 | - const DRIVING = 'Driving'; |
|
7 | - const WALKING = 'Walking'; |
|
8 | - const TRUCKING = 'Trucking'; |
|
9 | - const CYCLING = 'Cycling'; |
|
10 | - const TRANSIT = 'Transit'; |
|
6 | + const DRIVING = 'Driving'; |
|
7 | + const WALKING = 'Walking'; |
|
8 | + const TRUCKING = 'Trucking'; |
|
9 | + const CYCLING = 'Cycling'; |
|
10 | + const TRANSIT = 'Transit'; |
|
11 | 11 | } |
@@ -3,26 +3,26 @@ |
||
3 | 3 | |
4 | 4 | class StatusUpdateType |
5 | 5 | { |
6 | - const PICKUP = 'pickup'; |
|
7 | - const DROPOFF = 'dropoff'; |
|
8 | - const NOANSWER = 'noanswer'; |
|
9 | - const NOTFOUND = 'notfound'; |
|
10 | - const NOTPAID = 'notpaid'; |
|
11 | - const PAID = 'paid'; |
|
12 | - const WRONGDELIVERY = 'wrongdelivery'; |
|
13 | - const WRONGADDRESSRECIPIENT = 'wrongaddressrecipient'; |
|
14 | - const NOTPRESENT = 'notpresent'; |
|
15 | - const PARTS_MISSING = 'parts_missing'; |
|
16 | - const SERVICE_RENDERED = 'service_rendered'; |
|
17 | - const FOLLOW_UP = 'follow_up'; |
|
18 | - const LEFT_INFORMATION = 'left_information'; |
|
19 | - const SPOKE_WITH_DECISION_MAKER = 'spoke_with_decision_maker'; |
|
20 | - const SPOKE_WITH_DECISION_INFLUENCER = 'spoke_with_decision_influencer'; |
|
21 | - const SPOKE_WITH_DECISION_INFLUENCER = 'spoke_with_decision_influencer'; |
|
22 | - const COMPETITIVE_ACCOUNT = 'competitive_account'; |
|
23 | - const SCHEDULED_FOLLOW_UP_MEETING = 'scheduled_follow_up_meeting'; |
|
24 | - const SCHEDULED_LUNCH = 'scheduled_lunch'; |
|
25 | - const SCHEDULED_PRODUCT_DEMO = 'scheduled_product_demo'; |
|
26 | - const SCHEDULED_CLINICAL_DEMO = 'scheduled_clinical_demo'; |
|
27 | - const NO_OPPORTUNITY = 'no_opportunity'; |
|
6 | + const PICKUP = 'pickup'; |
|
7 | + const DROPOFF = 'dropoff'; |
|
8 | + const NOANSWER = 'noanswer'; |
|
9 | + const NOTFOUND = 'notfound'; |
|
10 | + const NOTPAID = 'notpaid'; |
|
11 | + const PAID = 'paid'; |
|
12 | + const WRONGDELIVERY = 'wrongdelivery'; |
|
13 | + const WRONGADDRESSRECIPIENT = 'wrongaddressrecipient'; |
|
14 | + const NOTPRESENT = 'notpresent'; |
|
15 | + const PARTS_MISSING = 'parts_missing'; |
|
16 | + const SERVICE_RENDERED = 'service_rendered'; |
|
17 | + const FOLLOW_UP = 'follow_up'; |
|
18 | + const LEFT_INFORMATION = 'left_information'; |
|
19 | + const SPOKE_WITH_DECISION_MAKER = 'spoke_with_decision_maker'; |
|
20 | + const SPOKE_WITH_DECISION_INFLUENCER = 'spoke_with_decision_influencer'; |
|
21 | + const SPOKE_WITH_DECISION_INFLUENCER = 'spoke_with_decision_influencer'; |
|
22 | + const COMPETITIVE_ACCOUNT = 'competitive_account'; |
|
23 | + const SCHEDULED_FOLLOW_UP_MEETING = 'scheduled_follow_up_meeting'; |
|
24 | + const SCHEDULED_LUNCH = 'scheduled_lunch'; |
|
25 | + const SCHEDULED_PRODUCT_DEMO = 'scheduled_product_demo'; |
|
26 | + const SCHEDULED_CLINICAL_DEMO = 'scheduled_clinical_demo'; |
|
27 | + const NO_OPPORTUNITY = 'no_opportunity'; |
|
28 | 28 | } |
@@ -3,7 +3,7 @@ |
||
3 | 3 | |
4 | 4 | class OptimizationType |
5 | 5 | { |
6 | - const DISTANCE = 'Distance'; |
|
7 | - const TIME = 'Time'; |
|
8 | - const TIME_WITH_TRAFFIC = 'timeWithTraffic'; |
|
6 | + const DISTANCE = 'Distance'; |
|
7 | + const TIME = 'Time'; |
|
8 | + const TIME_WITH_TRAFFIC = 'timeWithTraffic'; |
|
9 | 9 | } |
@@ -3,10 +3,10 @@ |
||
3 | 3 | |
4 | 4 | class OptimizationStates |
5 | 5 | { |
6 | - const INITIAL = 1; |
|
7 | - const MATRIX_PROCESSING = 2; |
|
8 | - const OPTIMIZING = 3; |
|
9 | - const OPTIMIZED = 4; |
|
10 | - const ERROR = 5; |
|
11 | - const COMPUTING_DIRECTIONS = 6; |
|
6 | + const INITIAL = 1; |
|
7 | + const MATRIX_PROCESSING = 2; |
|
8 | + const OPTIMIZING = 3; |
|
9 | + const OPTIMIZED = 4; |
|
10 | + const ERROR = 5; |
|
11 | + const COMPUTING_DIRECTIONS = 6; |
|
12 | 12 | } |
@@ -3,7 +3,7 @@ |
||
3 | 3 | |
4 | 4 | class TerritoryTypes |
5 | 5 | { |
6 | - const CIRCLE = 'circle'; |
|
7 | - const POLY = 'poly'; |
|
8 | - const RECT = 'rect'; |
|
6 | + const CIRCLE = 'circle'; |
|
7 | + const POLY = 'poly'; |
|
8 | + const RECT = 'rect'; |
|
9 | 9 | } |
@@ -14,8 +14,8 @@ discard block |
||
14 | 14 | Route4Me::setApiKey('11111111111111111111111111111111'); |
15 | 15 | |
16 | 16 | $activityParameters = ActivityParameters::fromArray(array( |
17 | - "limit" => 10, |
|
18 | - "offset" => 0 |
|
17 | + "limit" => 10, |
|
18 | + "offset" => 0 |
|
19 | 19 | )); |
20 | 20 | |
21 | 21 | $activities = new ActivityParameters(); |
@@ -23,6 +23,6 @@ discard block |
||
23 | 23 | $results = $activities->getValue($actresults, "results"); |
24 | 24 | |
25 | 25 | foreach ($results as $result) { |
26 | - Route4Me::simplePrint($result); |
|
27 | - echo "<br>"; |
|
26 | + Route4Me::simplePrint($result); |
|
27 | + echo "<br>"; |
|
28 | 28 | } |