Search in sources :

Example 1 with Address

use of amosalexa.services.bankcontact.Address in project amos-ss17-alexa by c-i-ber.

the class LocationTest method placesTest.

@Test
public void placesTest() throws InterruptedException {
    Address dummyAddress = new Address();
    String slotValue = "Sparkasse";
    LatLng deviceLocation = GeoCoder.getLatLng(dummyAddress);
    List<Place> places = PlaceFinder.findNearbyPlace(deviceLocation, slotValue);
    Place place = PlaceFinder.findOpeningHoursPlace(places, slotValue);
    log.warn("Addresse: " + place.getAddress());
    for (Hours.Period period : place.getHours().getPeriods()) {
        log.info("Place: " + period.getOpeningDay());
        log.info("Place: " + period.getOpeningTime());
        log.info("Place: " + period.getClosingTime());
    }
}
Also used : Address(amosalexa.services.bankcontact.Address) Hours(se.walkercrou.places.Hours) LatLng(com.google.maps.model.LatLng) Place(se.walkercrou.places.Place) Test(org.junit.Test)

Aggregations

Address (amosalexa.services.bankcontact.Address)1 LatLng (com.google.maps.model.LatLng)1 Test (org.junit.Test)1 Hours (se.walkercrou.places.Hours)1 Place (se.walkercrou.places.Place)1