Download Shareware and Freeware Software for Windows, Linux, Macintosh, PDA

line Home  |  About Us  |  Link To Us  |  FAQ  |  Contact

Serving Software Downloads in 956 Categories, Downloaded 50.324.245 Times

Data::Serializer 0.41

  Date Added: July 14, 2010  |  Visits: 917

Data::Serializer

Report Broken Link
Printer Friendly Version


Product Homepage
Download (93 downloads)



Data::Serializer package contains modules that serialize data structures. SYNOPSIS use Data::Serializer; $obj = Data::Serializer->new(); $obj = Data::Serializer->new( serializer => Storable, digester => MD5, cipher => DES, secret => my secret, compress => 1, ); $serialized = $obj->serialize({a => [1,2,3],b => 5}); $deserialized = $obj->deserialize($serialized); print "$deserialized->{b}n"; Provides a unified interface to the various serializing modules currently available. Adds the functionality of both compression and encryption. EXAMPLES Please see Data::Serializer::Cookbook(3) METHODS new - constructor $obj = Data::Serializer->new(); $obj = Data::Serializer->new( serializer => Data::Dumper, digester => SHA-256, cipher => Blowfish, secret => undef, portable => 1, compress => 0, serializer_token => 1, options => {}, ); new is the constructor object for Data::Serializer objects. The default serializer is Data::Dumper The default digester is SHA-256 The default cipher is Blowfish The default secret is undef The default portable is 1 The default encoding is hex The default compress is 0 The default compressor is Compress::Zlib The default serializer_token is 1 The default options is {} (pass nothing on to serializer) serialize - serialize reference $serialized = $obj->serialize({a => [1,2,3],b => 5}); Serializes the reference specified. Will compress if compress is a true value. Will encrypt if secret is defined. deserialize - deserialize reference $deserialized = $obj->deserialize($serialized); Reverses the process of serialization and returns a copy of the original serialized reference. freeze - synonym for serialize $serialized = $obj->freeze({a => [1,2,3],b => 5}); thaw - synonym for deserialize $deserialized = $obj->thaw($serialized); raw_serialize - serialize reference in raw form $serialized = $obj->raw_serialize({a => [1,2,3],b => 5}); This is a straight pass through to the underlying serializer, nothing else is done. (no encoding, encryption, compression, etc) raw_deserialize - deserialize reference in raw form $deserialized = $obj->raw_deserialize($serialized); This is a straight pass through to the underlying serializer, nothing else is done. (no encoding, encryption, compression, etc) secret - specify secret for use with encryption $obj->secret(mysecret); Changes setting of secret for the Data::Serializer object. Can also be set in the constructor. If specified than the object will utilize encryption. portable - encodes/decodes serialized data Uses encoding method to ascii armor serialized data Aids in the portability of serialized data. compress - compression of data Compresses serialized data. Default is not to use it. Will compress if set to a true value $obj->compress(1); serializer - change the serializer Currently have 8 supported serializers: Storable, FreezeThaw, Data::Denter, Config::General, YAML, PHP::Serialization, XML::Dumper, and Data::Dumper. Default is to use Data::Dumper. Each serializer has its own caveats about usage especially when dealing with cyclical data structures or CODE references. Please see the appropriate documentation in those modules for further information. cipher - change the cipher method Utilizes Crypt::CBC and can support any cipher method that it supports. digester - change digesting method Uses Digest so can support any digesting method that it supports. Digesting function is used internally by the encryption routine as part of data verification. compressor - changes compresing module This method is included for possible future inclusion of alternate compression method Currently Compress::Zlib is the only supported compressor. encoding - change encoding method Encodes data structure in ascii friendly manner. Currently the only valid options are hex, or b64. The b64 option uses Base64 encoding provided by MIME::Base64, but strips out newlines. serializer_token - add usage hint to data Data::Serializer prepends a token that identifies what was used to process its data. This is used internally to allow runtime determination of how to extract Serialized data. Disabling this feature is not recommended. options - pass options through to underlying serializer Currently is only supported by Config::General, and XML::Dumper. my $obj = Data::Serializer->new(serializer => Config::General, options => { -LowerCaseNames => 1, -UseApacheInclude => 1, -MergeDuplicateBlocks => 1, -AutoTrue => 1, -InterPolateVars => 1 }, ) or die "$!n"; or my $obj = Data::Serializer->new(serializer => XML::Dumper, options => { dtd => 1, } ) or die "$!n"; store - serialize data and write it to a file (or file handle) $obj->store({a => [1,2,3],b => 5},$file, [$mode, $perm]); or $obj->store({a => [1,2,3],b => 5},$fh); Serializes the reference specified using the serialize method and writes it out to the specified file or filehandle. If a file path is specified you may specify an optional mode and permission as the next two arguments. See IO::File for examples. Trips an exception if it is unable to write to the specified file. retrieve - read data from file (or file handle) and return it after deserialization my $ref = $obj->retrieve($file); or my $ref = $obj->retrieve($fh); Reads first line of supplied file or filehandle and returns it deserialized..

Requirements: No special requirements
Platforms: Linux
Keyword: Data Dataserializer Default File Libraries Programming Serialize Serialized Serialized Data Serializer Xml
Users rating: 0/10

License: Freeware Size: 25.6 KB
USER REVIEWS
More Reviews or Write Review


DATA::SERIALIZER RELATED
Database Tools  -  Data to XML 1.0
Data to XML can be used to generate XML documents from data stored in a MySQL database. It can execute a given SQL SELECT query and generate a XML document with query result data.
51.2 KB  
Libraries  -  GDS2 2.09a
GDS2 is a module for quickly creating programs to read and/or write GDS2 files. Create Method new - open gds2 file usage: my $gds2File = new GDS2(-fileName => "filename.gds2"); ## to read my $gds2File2 = new GDS2(-fileName =>...
10.24 KB  
Libraries  -  XML::Filter::DataIndenter 0.1
XML::Filter::DataIndenter is a SAX2 Indenter for data oriented XML. SYNOPSIS use XML::Filter::DataIndenter; use XML::SAX::Machines qw( Pipeline ); Pipeline( XML::Filter::DataIndenter => *STDOUT ); ALPHA CODE ALERT: This is the first...
3.07 KB  
Libraries  -  XML::LibXML::Parser 1.63
XML::LibXML::Parser is a Perl module to parse XML Data with XML::LibXML. SYNOPSIS $parser = XML::LibXML->new(); $doc = $parser->parse_file( $xmlfilename ); $doc = $parser->parse_fh( $io_fh ); $doc = $parser->parse_string( $xmlstring); $doc...
256 KB  
Database Tools  -  Free DBF Viewer 10.0
Free DBF Viewer (xBaseView DBF Viewer & DBF Converter) supports dBase, Clipper, FoxPro, Visual FoxPro and other DBF file formats. It supports the typical operations for databases, data export/import and SQL queries. In addition, this tool supports...
1.24 MB  
Libraries  -  App::Conf::File 0.965
App::Conf::File is a Perl module to load and access configuration data. SYNOPSIS use App::Conf; $config = App::Conf->new(); $config = App::Conf->new(configFile => $file); print $config->dump(), "n"; # use Data::Dumper to spit out the Perl...
122.88 KB  
Libraries  -  File::Find::Similars 1.1
File::Find::Similars is a Similar files locator. SYNOPSIS use File::Find::Similars; File::Find::Similars->init(0, @ARGV); similarity_check_name(); Similar-sized and similar-named files are picked as suspicious candidates of duplicated...
10.24 KB  
Libraries  -  Java::SJ::Config 0.01
Java::SJ::Config is a Perl module that represents SJ Configuration File. It uses XML::XPath to parse configuration files and generates objects to represent the directives. Unless youre working on the module what you really want to know is what...
18.43 KB  
Libraries  -  MARC::XML 0.4
MARC::XML is a subclass of MARC.pm to provide XML support. SYNOPSIS use MARC::XML; #read in some MARC and output some XML $myobject = MARC::XML->new("marc.mrc","usmarc"); $myobject->output({file=>">marc.xml",format=>"xml"}); #read in...
51.2 KB  
Libraries  -  Rails Gallery Generator 0.0a4
Rails-gallery provides a generator for file upload gallerys. Theres no user management included; the generator just provides the skel for your agile Web gallery. Whats New in This Release: - Added model Gallery - Added multiple-gallery...
19.46 KB  
NEW DOWNLOADS IN PROGRAMMING, LIBRARIES
Programming  -  Cedalion for Linux 0.2.6
Cedalion is a programming language that allows its users to add new abstractions and define (and use) internal DSLs. Its innovation is in the fact that it uses projectional editing to allow the new abstractions to have no syntactic limitations.
471.04 KB  
Programming  -  Math::GMPf 0.29
Math::GMPf - perl interface to the GMP library's floating point (mpf) functions.
30.72 KB  
Programming  -  Net::Wire10 1.08
Net::Wire10 is a Pure Perl connector that talks to Sphinx, MySQL and Drizzle servers. Net::Wire10 implements the low-level network protocol, alias the MySQL wire protocol version 10, necessary for talking to one of the aforementioned...
30.72 KB  
Programming  -  logilab-common 0.56.2
a bunch of modules providing low level functionnalities shared among some python projects devel Please note that some of the modules have some extra dependencies. For instance, logilab.common.db will require a db-api 2.0 compliant...
174.08 KB  
Programming  -  OpenSSL for linux 1.0.0a
The OpenSSL Project is a collaborative effort to develop a robust, commercial-grade, full-featured, and Open Source toolkit implementing the Secure Sockets Layer (SSL v2/v3) and Transport Layer Security (TLS v1) protocols as well as a...
3.83 MB  
Libraries  -  wolfSSL 4.0.0
The wolfSSL embedded SSL/TLS library is a lightweight SSL library written in ANSI standard C and targeted for embedded and RTOS environments - primarily because of its small size, speed, and feature set. It is commonly used in standard operating...
3.88 MB  
Libraries  -  EuGTK 4.8.9
Makes it easy to develop good- looking, fast, cross-platform programs that run on Linux, OS X, and Windows. Euphoria is a very fast interpreted/compiled language with straight-forward syntax. EuGTK allows programming in a clean, object-oriented...
10.68 MB  
Libraries  -  Linux User Group Library Manager 1.0
The LUG Library Manager is a project to help Linux User Groups start their own library. A LUG library is helpful to the community at large because it increases access to information, and gives everyone the opportunity to become more knowledgeable.
5.35 KB  
Libraries  -  Module::MakefilePL::Parse 0.12
Module::MakefilePL::Parse is a Perl module to parse required modules from Makefile.PL. SYNOPSIS use Module::MakefilePL::Parse; open $fh, Makefile.PL; $parser = Module::MakefilePL::Parse->new( join("", ) ); $info = $parser->required;...
8.19 KB  
Libraries  -  sqlpp 0.06
sqlpp Perl package is a SQL preprocessor. sqlpp is a conventional cpp-alike preprocessor taught to understand SQL ( PgSQL, in particular) syntax specificities. In addition to the standard #define/#ifdef/#else/#endif cohort, provides also...
10.24 KB