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

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

Serving Software Downloads in 976 Categories, Downloaded 29.624.089 Times

File::ShareDir 1.00

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

File::ShareDir

Report Broken Link
Printer Friendly Version


Product Homepage
Download (18 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
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  
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  
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  
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  -  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  
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  -  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  
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  -  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  
NEW DOWNLOADS IN LINUX SOFTWARE, PROGRAMMING
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  
Linux Software  -  SLAX 6.0+
Slax is a modern, portable, small and fast Linux operating system with a modular approach and outstanding design. Despite its small size, Slax provides a wide collection of pre-installed software for daily use, including a well organized graphical...
190 KB  
Linux Software  -  GTK+ 2.5
GTK+, which stands for the GIMP Toolkit, is a library for creating graphical user interfaces for the X Window System. It is designed to be small, efficient, and flexible. GTK+ is written in C with a very object-oriented approach. Language bindings...
60 MB  
Programming  -  FLEX-db Digital Asset Manager 3.0.9
FLEX-db - an enterprise Digital Asset Manager (DAM). It ingests and links metadata with files, creates thumbnails, and processes files using business rules. FLEX-db has a JSP client, Java app server for file input and output and an EJB metadata...
21.57 MB  
Programming  -  Libicom 0.9.0
The libicom library is a character based dynamicly linked library for Linux. It is used to remotely control the Icom IC-R8500 wide band receiver via an RS232 link. All call and return parameters to the control functions are character string based....
20.48 KB  
Programming  -  dotdesktop 0.3
Dotdesktop library provides ability to parse desktop entry file and access the information in a convenient way. Desktop entry file format is defined by freedesktop.org, it is used to describe information about an application such as the name and...
327.68 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  -  libyasl 0.2
Libyasl is a C++ class library to easily realize TCP/UDP/Multicast clientsand servers in IPv4 and IPv6 environments under GNU/Linux systems.
143.36 KB