@@ -860,36 +860,95 @@ public URL toUrl(@NonNull String accessToken) {
860860 .append (String .format ("/%s" , profile ()))
861861 .append (String .format ("/%s" , coordinates ()))
862862 .append (String .format ("?access_token=%s" , accessToken ))
863- .append (String .format ("&alternatives=%s" , alternatives ()))
864- .append (String .format ("&geometries=%s" , geometries ()))
865- .append (String .format ("&overview=%s" , overview ()))
866- .append (String .format ("&radiuses=%s" , radiuses ()))
867- .append (String .format ("&steps=%s" , steps ()))
868- .append (String .format ("&bearings=%s" , bearings ()))
869- .append (String .format ("&layers=%s" , layers ()))
870- .append (String .format ("&continue_straight=%s" , continueStraight ()))
871- .append (String .format ("&annotations=%s" , annotations ()))
872- .append (String .format ("&language=%s" , language ()))
873- .append (String .format ("&roundabout_exits=%s" , roundaboutExits ()))
874- .append (String .format ("&voice_instructions=%s" , voiceInstructions ()))
875- .append (String .format ("&banner_instructions=%s" , bannerInstructions ()))
876- .append (String .format ("&voice_units=%s" , voiceUnits ()))
877- .append (String .format ("&exclude=%s" , exclude ()))
878- .append (String .format ("&include=%s" , include ()))
879- .append (String .format ("&approaches=%s" , approaches ()))
880- .append (String .format ("&waypoints=%s" , waypointIndices ()))
881- .append (String .format ("&waypoint_names=%s" , waypointNames ()))
882- .append (String .format ("&waypoint_targets=%s" , waypointTargets ()))
883- .append (String .format ("&enable_refresh=%s" , enableRefresh ()))
884- .append (String .format ("&walking_speed=%s" , walkingSpeed ()))
885- .append (String .format ("&walkway_bias=%s" , walkwayBias ()))
886- .append (String .format ("&alley_bias=%s" , alleyBias ()))
887- .append (String .format ("&snapping_include_closures=%s" , snappingIncludeClosures ()))
888- .append (String .format ("&arrive_by=%s" , arriveBy ()))
889- .append (String .format ("&depart_at=%s" , departAt ()))
890- .append (String .format ("&max_height=%s" , maxHeight ()))
891- .append (String .format ("&max_width=%s" , maxWidth ()))
892- .append (String .format ("&metadata=%s" , metadata ()));
863+ .append (String .format ("&geometries=%s" , geometries ()));
864+
865+ if (alternatives () != null ) {
866+ sb .append (String .format ("&alternatives=%s" , alternatives ()));
867+ }
868+ if (overview () != null ) {
869+ sb .append (String .format ("&overview=%s" , overview ()));
870+ }
871+ if (radiuses () != null ) {
872+ sb .append (String .format ("&radiuses=%s" , radiuses ()));
873+ }
874+ if (steps () != null ) {
875+ sb .append (String .format ("&steps=%s" , steps ()));
876+ }
877+ if (bearings () != null ) {
878+ sb .append (String .format ("&bearings=%s" , bearings ()));
879+ }
880+ if (layers () != null ) {
881+ sb .append (String .format ("&layers=%s" , layers ()));
882+ }
883+ if (continueStraight () != null ) {
884+ sb .append (String .format ("&continue_straight=%s" , continueStraight ()));
885+ }
886+ if (annotations () != null ) {
887+ sb .append (String .format ("&annotations=%s" , annotations ()));
888+ }
889+ if (language () != null ) {
890+ sb .append (String .format ("&language=%s" , language ()));
891+ }
892+ if (roundaboutExits () != null ) {
893+ sb .append (String .format ("&roundabout_exits=%s" , roundaboutExits ()));
894+ }
895+ if (voiceInstructions () != null ) {
896+ sb .append (String .format ("&voice_instructions=%s" , voiceInstructions ()));
897+ }
898+ if (bannerInstructions () != null ) {
899+ sb .append (String .format ("&banner_instructions=%s" , bannerInstructions ()));
900+ }
901+ if (voiceUnits () != null ) {
902+ sb .append (String .format ("&voice_units=%s" , voiceUnits ()));
903+ }
904+ if (exclude () != null ) {
905+ sb .append (String .format ("&exclude=%s" , exclude ()));
906+ }
907+ if (include () != null ) {
908+ sb .append (String .format ("&include=%s" , include ()));
909+ }
910+ if (approaches () != null ) {
911+ sb .append (String .format ("&approaches=%s" , approaches ()));
912+ }
913+ if (waypointIndices () != null ) {
914+ sb .append (String .format ("&waypoints=%s" , waypointIndices ()));
915+ }
916+ if (waypointNames () != null ) {
917+ sb .append (String .format ("&waypoint_names=%s" , waypointNames ()));
918+ }
919+ if (waypointTargets () != null ) {
920+ sb .append (String .format ("&waypoint_targets=%s" , waypointTargets ()));
921+ }
922+ if (enableRefresh () != null ) {
923+ sb .append (String .format ("&enable_refresh=%s" , enableRefresh ()));
924+ }
925+ if (walkingSpeed () != null ) {
926+ sb .append (String .format ("&walking_speed=%s" , walkingSpeed ()));
927+ }
928+ if (walkwayBias () != null ) {
929+ sb .append (String .format ("&walkway_bias=%s" , walkwayBias ()));
930+ }
931+ if (alleyBias () != null ) {
932+ sb .append (String .format ("&alley_bias=%s" , alleyBias ()));
933+ }
934+ if (snappingIncludeClosures () != null ) {
935+ sb .append (String .format ("&snapping_include_closures=%s" , snappingIncludeClosures ()));
936+ }
937+ if (arriveBy () != null ) {
938+ sb .append (String .format ("&arrive_by=%s" , arriveBy ()));
939+ }
940+ if (departAt () != null ) {
941+ sb .append (String .format ("&depart_at=%s" , departAt ()));
942+ }
943+ if (maxHeight () != null ) {
944+ sb .append (String .format ("&max_height=%s" , maxHeight ()));
945+ }
946+ if (maxWidth () != null ) {
947+ sb .append (String .format ("&max_width=%s" , maxWidth ()));
948+ }
949+ if (metadata () != null ) {
950+ sb .append (String .format ("&metadata=%s" , metadata ()));
951+ }
893952
894953 try {
895954 return new URL (sb .toString ());
0 commit comments