Convert::Binary::C::Cached man page on Fedora

Man page or keyword search:  
man Server   31170 pages
apropos Keyword Search (all sections)
Output format
Fedora logo
[printable version]

Convert::Binary::C::CaUser(Contributed Perl DocumConvert::Binary::C::Cached(3)

NAME
       Convert::Binary::C::Cached - Caching for Convert::Binary::C

SYNOPSIS
	 use Convert::Binary::C::Cached;
	 use Data::Dumper;

	 #------------------------
	 # Create a cached object
	 #------------------------
	 $c = Convert::Binary::C::Cached->new(
		Cache	=> '/tmp/cache.c',
		Include => [
		  '/usr/lib/gcc/i686-pc-linux-gnu/4.5.2/include',
		  '/usr/lib/gcc/i686-pc-linux-gnu/4.5.2/include-fixed',
		  '/usr/include',
		],
	      );

	 #----------------------------------------------------
	 # Parse 'time.h' and dump the definition of timespec
	 #----------------------------------------------------
	 $c->parse_file('time.h');

	 print Dumper($c->struct('timespec'));

DESCRIPTION
       Convert::Binary::C::Cached simply adds caching capability to
       Convert::Binary::C. You can use it in just the same way that you would
       use Convert::Binary::C. The interface is exactly the same.

       To use the caching capability, you must pass the "Cache" option to the
       constructor. If you don't pass it, you will receive an ordinary
       Convert::Binary::C object. The argument to the "Cache" option is the
       file that is used for caching this object.

       The caching algorithm automatically detects when the cache file cannot
       be used and the original code has to be parsed.	In that case, the
       cache file is updated. An update of the cache file can be triggered by
       one or more of the following factors:

       · The cache file doesn't exist, which is obvious.

       · The cache file is corrupt, i.e. cannot be parsed.

       · The object's configuration has changed.

       · The embedded code for a "parse" method call has changed.

       · At least one of the files that the object depends on does not exist
	 or has a different size or a different modification or change
	 timestamp.

LIMITATIONS
       You cannot call "parse" or "parse_file" more that once when using a
       Convert::Binary::C::Cached object. This isn't a big problem, as you
       usually don't call them multiple times.

       If a dependency file changes, but the change affects neither the size
       nor the timestamps of that file, the caching algorithm cannot detect
       that an update is required.

COPYRIGHT
       Copyright (c) 2002-2011 Marcus Holland-Moritz. All rights reserved.
       This program is free software; you can redistribute it and/or modify it
       under the same terms as Perl itself.

SEE ALSO
       See Convert::Binary::C.

perl v5.14.1			  2011-04-11	 Convert::Binary::C::Cached(3)
[top]

List of man pages available for Fedora

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net