NAME

STIX::Location - STIX Domain Object (SDO) - Location

SYNOPSIS

use STIX::Location;

my $location = STIX::Location->new();

DESCRIPTION

A Location represents a geographic location. The location may be described as any, some or all of the following: region (e.g., North America), civic address (e.g. New York, US), latitude and longitude.

METHODS

STIX::Location inherits all methods from STIX::Common::Properties and implements the following new ones.

STIX::Location->new(%properties)

Create a new instance of STIX::Location.

$location->administrative_area

The state, province, or other sub-national administrative area that this Location describes.

$location->city

The city that this Location describes.

$location->country

The country that this Location describes.

$location->description

A textual description of the Location.

$location->id
$location->latitude

The latitude of the Location in decimal degrees.

$location->longitude

The longitude of the Location in decimal degrees.

$location->name

A name used to identify the Location.

$location->postal_code

The postal code for this Location.

$location->precision

Defines the precision of the coordinates specified by the latitude and longitude properties, measured in meters.

$location->region

The region that this Location describes. (See REGION in STIX::Common::Enum)

$location->street_address

The street address that this Location describes.

$location->type

The type of this object, which MUST be the literal location.

HELPERS

$location->TO_JSON

Encode the object in JSON.

$location->to_hash

Return the object HASH.

$location->to_string

Encode the object in JSON.

$location->validate

Validate the object using JSON Schema (see STIX::Schema).

SUPPORT

Bugs / Feature Requests

Please report any bugs or feature requests through the issue tracker at https://github.com/giterlizzi/perl-STIX/issues. You will be notified automatically of any progress on your issue.

Source Code

This is open source software. The code repository is available for public review and contribution under the terms of the license.

https://github.com/giterlizzi/perl-STIX

git clone https://github.com/giterlizzi/perl-STIX.git

AUTHOR

  • Giuseppe Di Terlizzi <gdt@cpan.org>

LICENSE AND COPYRIGHT

This software is copyright (c) 2024 by Giuseppe Di Terlizzi.

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