PropertiesLoader.pm

Summary
PropertiesLoader.pm
JOINCACHE::PropertiesLoaderReads a configuration file for joinCache, respect the IniFiles format, but consider order.
PROPLOADERDefine allowed sections
Constructors
new
_loadRead line by line (order is important), no library is used.
readCompositionReads a composition section line.
Tester
isConfSectionCheck section’s name.
Getters - Setters
getSourcePyramids
getPyramidSection
getLoggerSection
getCompositionSection
getBboxesSection
getProcessSection

JOINCACHE::PropertiesLoader

Exporter
JOINCACHE::PropertiesLoader

Reads a configuration file for joinCache, respect the IniFiles format, but consider order.  Possible sections are limited :

  • logger
  • pyramid
  • bboxes
  • composition
  • process

Using

use JOINCACHE::PropertiesLoader;

my $objPropLoader = JOINCACHE::PropertiesLoader->new("/home/IGN/properties.txt");

Attributes

configurationPathstring - Configuration file path.
loggerhash - Can be null
pyramidhash - Final pyramid’s parameters
bboxeshash - Defines identifiants with associated bounding boxes (as string)
compositionhash - Defines source pyramids for each level, extent, and order
level_id => priority => {
        bbox => bbox_id,
        pyr => descriptor_path,
}
sourceByLevelinteger hash - Precises the number of source pyramids for each level (to define priorities).
sourcePyramidsstring hash - Key is the descriptor’s path.  Just undefined values, to list used pyramids.
processhash - Generation parameters
Summary
PROPLOADERDefine allowed sections
Constructors
new
_loadRead line by line (order is important), no library is used.
readCompositionReads a composition section line.
Tester
isConfSectionCheck section’s name.
Getters - Setters
getSourcePyramids
getPyramidSection
getLoggerSection
getCompositionSection
getBboxesSection
getProcessSection

PROPLOADER

my %PROPLOADER

Define allowed sections

Constructors

new

sub new

_load

sub _load

Read line by line (order is important), no library is used.

Parameters (list)

filepathstring - Configuration file path, to read

See Also

isConfSection, <readCompositionLine>

readComposition

sub readCompositionLine

Reads a composition section line.  Determine sources by level and calculate priorities.

Parameters (list)

propstring - Composition’s name: levelId.bboxId
valstring - Composition’s value: pyrPath1,pyrPath2,pyrPath3

Tester

isConfSection

sub isConfSection

Check section’s name.  Possible values: ‘pyramid’,’process’,’composition’,’logger’,’bboxes’.

Parameters (list)

sectionstring - section’s name

Getters - Setters

getSourcePyramids

sub getSourcePyramids

getPyramidSection

sub getPyramidSection

getLoggerSection

sub getLoggerSection

getCompositionSection

sub getCompositionSection

getBboxesSection

sub getBboxesSection

getProcessSection

sub getProcessSection
my %PROPLOADER
Define allowed sections
sub new
sub _load
Read line by line (order is important), no library is used.
sub readCompositionLine
Reads a composition section line.
sub isConfSection
Check section’s name.
sub getSourcePyramids
sub getPyramidSection
sub getLoggerSection
sub getCompositionSection
sub getBboxesSection
sub getProcessSection
Close