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.168.014 Times

File::ShareDir 1.00

Company: Adam Kennedy
Date Added: November 22, 2013  |  Visits: 321

File::ShareDir

Report Broken Link
Printer Friendly Version


Product Homepage
Download (36 downloads)



File::ShareDir is a Perl module that provides a companion to Class::Inspector and File::HomeDir, modules that take a process that is well-known by advanced Perl developers but gets a little tricky, and make it more available to the larger Perl community.<br /><br />Quite often you want or need your Perl module (CPAN or otherwise) to have access to a large amount of read-only data that is stored on the file-system at run-time.<br /><br />On a linux-like system, this would be in a place such as /usr/share, however Perl runs on a wide variety of different systems, and so the use of any one location is unreliable.<br /><br />Perl provides a little-known method for doing this, but almost nobody is aware that it exists. As a result, module authors often go through some very strange ways to make the data available to their code.<br /><br />The most common of these is to dump the data out to an enormous Perl data structure and save it into the module itself. The result are enormous multi-megabyte .pm files that chew up a lot of memory needlessly.<br /><br />Another method is to put the data "file" after the __DATA__ compiler tag and limit yourself to access as a filehandle.<br /><br />The problem to solve is really quite simple.<br /><br /> 1. Write the data files to the system at install time.<br /> <br /> 2. Know where you put them at run-time.<br /><br />Perl's install system creates an "auto" directory for both every distribution and for every module file.<br /><br />These are used by a couple of different auto-loading systems to store code fragments generated at install time, and various other modules written by the Perl "ancient masters".<br /><br />But the same mechanism is available to any dist or module to store any sort of data.<br /><br />SYNOPSIS<br /><br /> use File::SharedDir ':ALL';<br /> <br /> # Where are distribution-level shared data files kept<br /> $dir = dist_dir('File-ShareDir');<br /> <br /> # Where are module-level shared data files kept<br /> $dir = module_dir('File::ShareDir');<br /> <br /> # Find a specific file in our dist/module shared dir<br /> $file = dist_file( 'File-ShareDir', 'file/name.txt');<br /> $file = module_file('File::ShareDir', 'file/name.txt');<br /> <br /> # Like module_file, but search up the inheritance tree<br /> $file = class_file( 'Foo::Bar', 'file/name.txt' );

Requirements: No special requirements
Platforms: *nix, Linux
Keyword: Access Enormous Filenametxt Files Fragments Install Method Module Modules Result Shared Store System Systems
Users rating: 0/10

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


FILE::SHAREDIR RELATED
Installer/Uninstaller Tools  -  Install Kernel 0.9.3
Install Kernel interfaces with the Linux operating system by running a series of functions or groups of commands that automate the compiling or recompiling and installation process. Install Kernel project consists of three groups of functions:...
4.1 KB  
Programming  -  Config::GitLike 1.04
This module handles interaction with configuration files of the style used by the version control system Git. It can both parse and modify these files, as well as create entirely new ones. You only need to know a few things about the...
40.96 KB  
Modules  -  jOrange Quick Access Bar 1.0.0
jOrange Quick Access Bar is a replacement for the standard User Status in the Joomla administration interface.Compared to the User Status bar, jOrange Quick Access Bar displays more detailed information about the visitors on your site and your...
10 KB  
Libraries  -  NDBM_File 5.8.8
NDBM_File is a Perl module that allows tied access to ndbm files. SYNOPSIS use Fcntl; # For O_RDWR, O_CREAT, etc. use NDBM_File; tie(%h, NDBM_File, filename, O_RDWR|O_CREAT, 0666) or die "Couldnt tie NDBM file filename: $!; aborting"; #...
12.2 MB  
Libraries  -  ODBM_File 5.8.8
ODBM_File is a Perl module to allow tied access to odbm files. SYNOPSIS use Fcntl; # For O_RDWR, O_CREAT, etc. use ODBM_File; # Now read and change the hash $h{newkey} = newvalue; print $h{oldkey}; ... untie %h; ODBM_File establishes...
12.2 MB  
Libraries  -  RPM::Util::Files 0.10
RPM::Util::Files is a Perl module to generate %files list in RPM Specfile. SYNOPSIS use RPM::Util::Files; my $util = RPM::Util::Files->new({ build_root => /var/tmp/some-package-version-root, docs_filters => [ sub { my $entry = shift;...
5.12 KB  
Modules  -  Plugin Manager 6.x-1.3 1.0
After all selections are made the module will download the appropriate files and install them.InstallationUnpack in your modules folder (usually /sites/all/modules/) and enable under Administer > Site Building > Modules. Key features "Plugin...
 
Modules  -  UC Free Order Payment Method 6.x-1.0-beta4
The UC Free Order Payment Method module works in conjunction with the payment checkout pane using the order total preview to present a "Free order" payment method to customers when their order total drops to $0.00 or less. By default, this method...
10 KB  
Modules  -  Jquery UI Dialog 6.x-1.10
In ShortIf you are not a developer or asked to install this module as a dependency, you most probably won't have any use for it. This module enables you to use jquery ui dialog in Drupal.Features yet implemented * It enables you to use JQuery UI...
20.48 KB  
Libraries  -  AnyData::Format::Mp3 0.10
AnyData::Format::Mp3 is a tied hash and DBI access to Mp3 files. SYNOPSIS use AnyData; my $playlist = adTie( Passwd, [c:/My Music/] ); while (my $song = each %$playlist){ print $song->{artist} if $song->{genre} eq Reggae } OR use DBI...
44.03 KB  
NEW DOWNLOADS IN LINUX SOFTWARE, PROGRAMMING
Linux Software  -  EasyEDA PCB Designer for Linux 2.0.0
EasyEDA, a great web based EDA(Electronics Design Automation) tool, online PCB tool, online PCB software for electronics engineers, educators, students, makers and enthusiasts. Theres no need to install any software. Just open EasyEDA in any...
34.4 MB  
Linux Software  -  wpCache® WordPress HTTP Cache 1.9
wpCache® is a high-performance, distributed object, caching system application, generic in nature, but intended for use in speeding up dynamic web applications, by decreasing database load time. wpCache® decreases dramatically the page...
3.51 MB  
Linux Software  -  Polling Autodialer Software 3.4
ICTBroadcast Auto Dialer software has a survey campaign for telephone surveys and polls. This auto dialer software automatically dials a list of numbers and asks them a set of questions that they can respond to, by using their telephone keypad....
488 B  
Linux Software  -  Total Video Converter Mac Free 3.5.5
Total Video Converter Mac Free developed by EffectMatrix Ltd is the official legal version of Total Video Converter which was a globally recognized brand since 2006. Total Video Converter Mac Free is a free but powerful all-in-one video...
17.7 MB  
Linux Software  -  Skeith mod_log_sql Analyzer 2.10beta2
Skeith is a php based front end for analyzing logs for Apache using mod_log_sql.
47.5 KB  
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