NAME
Oak::Filer::Component - Filer to save/load data into/from Components
SYNOPSIS
require Oak::Filer::Component;
my $filer = new Oak::Filer::Component(
FILENAME => "tralala.xml", # mandatory, any supported by DBI
)
my $hr_props = $filer->load("mine");
my $hr_owned = $filer->load("owned");
$filer->store(
mine => $hr_props,
owned => $hr_owned
);
DESCRIPTION
This module provides access for saving and reading data into a Component XML, to be used by components. Must pass XML FILENAME
- constructor
-
Overwrited to test the existance of XML file.
- load
-
Load the information from the XML file and return one of the following properties "mine" => the properties of the owner of this XML "owned" => a hash with all the owned components and their properties
Throws a Oak::Filer::Component::Error::ErrorReadingXML when there was something wrong when trying to read the XML file.
- store
-
Store the information into the XML file. You can pass any of these parameters, but you have to pass ALL the parameters, because the hash you pass as a parameter will overwrite the old hash. "mine" => the properties of the owner of this XML "owned" => a hash with all the owned components and their properties
Throws a Oak::Filer::Component::Error::ErrorReadingXML when there was something wrong when trying to read the XML file.
EXCEPTIONS
The following exceptions are introduced by Oak::Filer::Component
- Oak::Filer::Component::Error::ErrorReadingXML
-
This error is throwed when there is some problem with the XML while trying to read it.
- Oak::Filer::Component::Error::ErrorWritingXML
-
This error is throwed when there is some problem with the XML while trying to read it.
7 POD Errors
The following errors were encountered while parsing the POD:
- Around line 33:
'=item' outside of any '=over'
- Around line 51:
=cut found outside a pod block. Skipping to next block.
- Around line 53:
'=item' outside of any '=over'
- Around line 84:
=cut found outside a pod block. Skipping to next block.
- Around line 86:
'=item' outside of any '=over'
- Around line 193:
'=item' outside of any '=over'
- Around line 208:
'=item' outside of any '=over'