WWW::AzimuthAero::Utils - functions that can be used outside WWW::AzimuthAero::* packages
version 0.4
Some useful date manipulation and filtering functions
Get next dow-date following by specified date
By default all input and output dates in '%d.%m.%Y' format, but you can easily specified needed one or deturn DateTime object
get_next_dow_date( '7.06.2019', 7 )->dmy('.'); # '9.06.2019' get_next_dow_date( '7.06.2019', 3 )->dmy('.'); # '12.06.2019'
Get particular dates, based on min_date, max_date and days_of_week
min_date and max_date are in '%Y-%m-%d' format by default
get_dates_from_dows( min => '2019-06-01', max => '2019-10-26', 'days' => '16' );
Return sorted array
TO-DO: carefully check for max day without min day (result may not include it)
Filter dates by max and min dates
filter_dates( \@dates, max => '15.06.2019' ); filter_dates( \@dates, max => '15.06.2019', min => '07.06.2019' );
Extract global variable value from JavaScript code
remove newline symbols, leading and trailing whitespaces
Transform
[ [ 'ROV', 'MOW', 'LED' ], [ 'ROV', 'KRR', 'LED' ] ]
to
[ { from => 'ROV', via => 'MOW', to => 'LED' }, { from => 'ROV', via => 'KRR', to => 'LED' } ]
Pavel Serikov <pavelsr@cpan.org>
This software is copyright (c) 2019 by Pavel Serikov.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install WWW::AzimuthAero, copy and paste the appropriate command in to your terminal.
cpanm
cpanm WWW::AzimuthAero
CPAN shell
perl -MCPAN -e shell install WWW::AzimuthAero
For more information on module installation, please visit the detailed CPAN module installation guide.