All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.azure.maps.traffic.implementation.helpers.Utility Maven / Gradle / Ivy

Go to download

This package contains Microsoft Azure SDK for Traffic Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. Azure Maps Traffic REST APIs. Package tag 1.0-preview.

The newest version!
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

package com.azure.maps.traffic.implementation.helpers;

import java.util.Arrays;
import java.util.List;

import com.azure.core.models.GeoBoundingBox;
import com.azure.core.models.GeoPosition;
import com.azure.maps.traffic.implementation.models.LatLongPair;



public class Utility {
    public static List toBoundingBox(GeoBoundingBox boundingBox) {
        return Arrays.asList(boundingBox.getSouth(), boundingBox.getWest(), boundingBox.getNorth(), boundingBox.getEast());
    }
    public static List toCoordinates(GeoPosition geoPosition) {
        return Arrays.asList(geoPosition.getLatitude(), geoPosition.getLongitude());
    }

    public static GeoPosition toGeoPosition(LatLongPair latLongPair) {
        return new GeoPosition(latLongPair.getLongitude(), latLongPair.getLatitude());
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy