NAME

OpenGbg::Service::Bridge - Entry point to the Bridge service

VERSION

Version 0.1404, released 2018-05-19.

SYNOPSIS

    my $bridge = OpenGbg->new->bridge;
    my $response = $bridge->get_is_currently_open;

    print $response->is_open ? 'It is open' : 'It is closed';

DESCRIPTION

The Göta älvbron is a major bascule bridge in Gothenburg that opens more or less daily. This service publishes two methods with regards to its status.

Official documentation

See OpenGbg for general information.

METHODS

get_is_currently_open

This method is for checking if the bridge is currently open.

Returns a GetIsCurrentlyOpen object.

get_opened_status($startdate, $enddate)

This method is for checking when it was opened in the past.

$startdate and $enddate are mandatory filtering arguments, both are expected to be in the iso-8601 representation: yyyy-mm-dd. The ending date is not inclusive.

Returns a GetOpenedStatus object.

SOURCE

https://github.com/Csson/p5-OpenGbg

HOMEPAGE

https://metacpan.org/release/OpenGbg

AUTHOR

Erik Carlsson <info@code301.com>

COPYRIGHT AND LICENSE

This software is copyright (c) 2016 by Erik Carlsson.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.