<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;"># automatically generated file, don't edit



# Copyright 2011 David Cantrell, derived from data from libphonenumber
# http://code.google.com/p/libphonenumber/
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
package Number::Phone::StubCountry::SI;
use base qw(Number::Phone::StubCountry);

use strict;
use warnings;
use utf8;
our $VERSION = 1.20210309172132;

my $formatters = [
                {
                  'format' =&gt; '$1 $2',
                  'leading_digits' =&gt; '
            8[09]|
            9
          ',
                  'national_rule' =&gt; '0$1',
                  'pattern' =&gt; '(\\d{2})(\\d{3,6})'
                },
                {
                  'format' =&gt; '$1 $2',
                  'leading_digits' =&gt; '
            59|
            8
          ',
                  'national_rule' =&gt; '0$1',
                  'pattern' =&gt; '(\\d{3})(\\d{5})'
                },
                {
                  'format' =&gt; '$1 $2 $3',
                  'leading_digits' =&gt; '
            [37][01]|
            4[0139]|
            51|
            6
          ',
                  'national_rule' =&gt; '0$1',
                  'pattern' =&gt; '(\\d{2})(\\d{3})(\\d{3})'
                },
                {
                  'format' =&gt; '$1 $2 $3 $4',
                  'leading_digits' =&gt; '[1-57]',
                  'national_rule' =&gt; '(0$1)',
                  'pattern' =&gt; '(\\d)(\\d{3})(\\d{2})(\\d{2})'
                }
              ];

my $validators = {
                'fixed_line' =&gt; '
          (?:
            [1-357][2-8]|
            4[24-8]
          )\\d{6}
        ',
                'geographic' =&gt; '
          (?:
            [1-357][2-8]|
            4[24-8]
          )\\d{6}
        ',
                'mobile' =&gt; '
          65(?:
            1\\d|
            55|
            [67]0
          )\\d{4}|
          (?:
            [37][01]|
            4[0139]|
            51|
            6[489]
          )\\d{6}
        ',
                'pager' =&gt; '',
                'personal_number' =&gt; '',
                'specialrate' =&gt; '(
          89[1-3]\\d{2,5}|
          90\\d{4,6}
        )',
                'toll_free' =&gt; '80\\d{4,6}',
                'voip' =&gt; '
          (?:
            59\\d\\d|
            8(?:
              1(?:
                [67]\\d|
                8[0-489]
              )|
              2(?:
                0\\d|
                2[0-37-9]|
                8[0-2489]
              )|
              3[389]\\d
            )
          )\\d{4}
        '
              };
my %areanames = ();
$areanames{en} = {"38646", "Kranj",
"38637", "Celje\/Trbovlje",
"3861", "Ljubljana",
"38645", "Kranj",
"38636", "Celje\/Trbovlje",
"38635", "Celje\/Trbovlje",
"38647", "Kranj",
"38677", "Novo\ Mesto\/KrÅ¡ko",
"38657", "Gorica\/Koper\/Postojna",
"38676", "Novo\ Mesto\/KrÅ¡ko",
"38656", "Gorica\/Koper\/Postojna",
"38675", "Novo\ Mesto\/KrÅ¡ko",
"38655", "Gorica\/Koper\/Postojna",
"38633", "Celje\/Trbovlje",
"38673", "Novo\ Mesto\/KrÅ¡ko",
"38653", "Gorica\/Koper\/Postojna",
"38648", "Kranj",
"38638", "Celje\/Trbovlje",
"38658", "Gorica\/Koper\/Postojna",
"38678", "Novo\ Mesto\/KrÅ¡ko",
"38632", "Celje\/Trbovlje",
"38644", "Kranj",
"3862", "Maribor\/Ravne\ na\ KoroÅ¡kem\/Murska\ Sobota",
"38642", "Kranj",
"38634", "Celje\/Trbovlje",
"38652", "Gorica\/Koper\/Postojna",
"38672", "Novo\ Mesto\/KrÅ¡ko",
"38674", "Novo\ Mesto\/KrÅ¡ko",
"38654", "Gorica\/Koper\/Postojna",};

    sub new {
      my $class = shift;
      my $number = shift;
      $number =~ s/(^\+386|\D)//g;
      my $self = bless({ number =&gt; $number, formatters =&gt; $formatters, validators =&gt; $validators, areanames =&gt; \%areanames}, $class);
      return $self if ($self-&gt;is_valid());
      $number =~ s/^(?:0)//;
      $self = bless({ number =&gt; $number, formatters =&gt; $formatters, validators =&gt; $validators, areanames =&gt; \%areanames}, $class);
      return $self-&gt;is_valid() ? $self : undef;
    }
1;</pre></body></html>