NAME
Number::Phone::NO - Number::Phone country package for NO (Norway)
VERSION
version 0.11
SYNOPSIS
use Number::Phone;
use Number::Phone::NO;
Number::Phone::NO::is_valid("+47 2234 5123");
my $s = Number::Phone::NO::format("2234 5123");
$s eq "+47 22 34 51 23"
DESCRIPTION
Number::Phone::NO tries to provide the Number::Phone framework with support for norwegian phone numbers. Its data is based on the number plans provided by Post- og teletilsynet, which is a govermental institution.
METHODS
new $nr
Takes a number as its only argument, returning a blessed object if the number is valid, or undef on invalid.
areacode
Never returns anything, as we do not have reliable area-codes in Norway.
format
Formats the numbers according to Post- og teletilsynets recomendations.
operator
Returns the company that has been assigned the range the number lives in. Due to portability of numbers in Norway, this may no longer be the right operator.
country_code
Returns 47, which is the norwegian country code
location
Never returns anything since there is no way to tell from the public information.
regulator
Always returns Post- og teletilsynet
subscriber
Returns the 3-8 digits part of the phonenumer that isn't the country_code
areaname
Returns the name of the area the number was originaly allocated for. Due to number portability, this may no longer be the right area.
is_adult
Returns true for numbers in the ranges marked as premium rate services
is_allocated
Returns true for all numbers in ranges not marked as reserve or available
is_corporate
Always returns undef, as the data is inconclusive.
is_fixed_line
Always returns undef, as the data is inconclusive.
is_geographic
Always returns undef, as the data is inconclusive.
is_ipphone
Returns true for numbers within the ranges marked with IP
is_mobile
Returns true for numbers within tanges marked with GSM
is_network_service
Returns true for numbers in the 100-199 range, which includes emergency service etc.
is_pager
Returns undef, as the data is inconclusive.
is_personal
Returns undef, as the data is inconclusive.
is_specialrate
Returns true for numbers that are marked as some type of rate in the data
is_tollfree
Returns true for numbers marked as reversed charge
is_valid
Returns true if the number falls within a range.
CONFIGURATION AND ENVIRONMENT
Number::Phone::NO requires no configuration files or environment variables.
AUTHOR
Andreas Marienborg <andremar@cpan.org>
COPYRIGHT AND LICENSE
This software is copyright (c) 2013 by Andreas Marienborg.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.