NAME

Geo::Location::IP::Model::ConnectionType - IP connection details

VERSION

version 0.002

SYNOPSIS

use Geo::Location::IP::Database::Reader;
my $reader = Geo::Location::IP::Database::Reader->new(
  file => '/path/to/Connection-Type.mmdb',
);
eval {
  my $ct_model = $reader->connection_type(ip => '1.2.3.4');
  my $type     = $ct_model->connection_type;
  printf "connection type is %s\n", $type;
};

DESCRIPTION

This class contains details about an IP connection.

SUBROUTINES/METHODS

new

my $ct_model = Geo::Location::IP::Model::ConnectionType->new(
  connection_type => 'Dialup'.
  ip_address      => $ip_address,
);

Creates a new object with data from an IP address query in a Connection-Type database.

All fields may contain undefined values.

connection_type

my $type = $ct_model->connection_type;

Returns the connection type as a string.

See Geo::Location::IP::Record::Traits for a list of connection types.

ip_address

my $ip_address = $ct_model->ip_address;

Returns the IP address the data is for as a Geo::Location::IP::Address object.

DIAGNOSTICS

None.

CONFIGURATION AND ENVIRONMENT

None.

DEPENDENCIES

None.

INCOMPATIBILITIES

None.

BUGS AND LIMITATIONS

None known.

AUTHOR

Andreas Vögele <voegelas@cpan.org>

LICENSE AND COPYRIGHT

Copyright (C) 2025 Andreas Vögele

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