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

File::SmartNL 0.05

  Date Added: May 13, 2010  |  Visits: 1.008

File::SmartNL

Report Broken Link
Printer Friendly Version


Product Homepage
Download (94 downloads)



File::SmartNL is a slurp text files no matter the New Line (NL) sequence. SYNOPSIS ##### # Subroutine Interface # use File::SmartNL qw(config fin fout smartnl); $old_value = config( $option ); $old_value = config( $option => $new_value); (@all_options) = config( ); $data = smart_nl($data); $data = fin( $file_name, @options ); $char_count = fout($file_name, $data, @options); ###### # Object Interface # use File::SmartNL; $default_options = File::SmartNL->default(@options); $old_value = $default_options->config( $option ); $old_value = $default_options->config( $option => $new_value); (@all_options) = $default_options->config( ); $data = File::SmartNL->smart_nl($data); $data = File::SmartNL->fin( $file_name, @options ); $char_count = File::SmartNL->fout($file_name, $data, @options); Generally, if a subroutine will process a list of options, @options, that subroutine will also process an array reference, @options, [@options], or hash reference, %options, {@options}. If a subroutine will process an array reference, @options, [@options], that subroutine will also process a hash reference, %options, {@options}. See the description for a subroutine for details and exceptions. Different operating systems have different sequences for new-lines. Historically when computers where first being born, one of the mainstays was the teletype. The teletype understood ASCII. The teletype was an automated typewriter that would perform a carriage return when it received an ASCII Carriage Return (CR), 15, character and a new line when it received a Line Feed (LF), 12 character. After some time came Unix. Unix had a tty driver that had a raw mode that sent data unprocessed to a teletype and a cooked mode that performed all kinds of translations and manipulations. Unix stored data internally using a single NL character at the ends of lines. The tty driver in the cooked mode would translate the New Line (NL) character to a CR,LF sequence. When driving a teletype, the physicall action of performing a carriage return took some time. By always putting the CR before the LF, the teletype would actually still be performing a carriage return when it received the LF and started a line feed. After some time came DOS. Since the tty driver is actually one of the largest peices of code for UNIX and DOS needed to run in very cramp space, the DOS designers decided, that instead of writing a tailored down tty driver, they would stored a CR,LF in the internal memory. Data internally would be either text data or binary data. Needless to say, after many years and many operating systems about every conceivable method of storing new lines may be found amoung the various operating systems. This greatly complicates moving files from one operating system to another operating system. The smart NL methods in this package are designed to take any combination of CR and NL and translate it into the special NL seqeunce used on the site operating system. Thus, by using these methods, the messy problem of moving files between operating systems is mostly hidden in these methods. By using the fin and fout methods, text files may be freely exchanged between operating systems without any other processing. The one thing not hidden is that the methods need to know if the data is text data or binary data. Normally, the assume the data is text and are overriden by setting the binary option. Perl 5.6 introduced a built-in smart nl functionality as an IO discipline :crlf. See Programming Perl by Larry Wall, Tom Christiansen and Jon Orwant, page 754, Chapter 29: Functions, open function. For Perl 5.6 or above, the :crlf IO discipline my be preferable over the smart_nl method of this program module..

Requirements: No special requirements
Platforms: Linux
Keyword: Carriage Return Cr Data Dos Lf Line New New Line No Matter Operating Operating Systems Options Smartnl Text Text Files
Users rating: 0/10

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


FILE::SMARTNL RELATED
Web Browsers  -  EbayHunter 1.0
Our software is a great new browser for Windows operating systems* with the added bonus of being able to search your local ebay listings for items that are pickup/collection only near to where you live. *XP users might need to install the .net...
65 KB  
Libraries  -  IPC::LDT 2.03
IPC::LDT is a Perl module that implements a length based IPC protocol. Interprocess communication often uses line (or record) oriented protocols. FTP, for example, usually is such a protocol: a client sends a command (e.g. "LS") which is...
13.31 KB  
Utilities  -  Align 1.6
ALIGN aligns data in ASCII text files into neat columns. Also converts comma-delimited files to columns with 2 spaces between each column. Input fields must be separated by commas or white space. Fields may contain spaces if they are enclosed in...
71 KB  
Development Editors  -  Unix <-> Windows Text Converter 0.3b
Unix Windows Text Converter is a simple Windows Shell Extension that converts text files from DOS to Unix format (New Line format from CRLF to LF) and vice versa.
285 KB  
Development Editors  -  JAG CrLf 2.1
On DOS/Windows system line breaks are represented by the characters Carriage-Return and Line-Feed, on UNIX/Linux systems only by the character Line-Feed, on the Macintosh again only the character Carriage-Return is used. Because many programs...
345 KB  
Modules  -  Making PayPal Return Order Data 1.0
osC's standard PayPal module does not include this line, which appears to be essential to the handshake working right between osC and PayPal.tep_draw_hidden_field('rm', 2) .See the attachment for installation details.
 
Utilities  -  Active@ Kill Disk - Hard Drive Eraser 2.0
Active@ KillDisk is a quality security application that destroys data permanently from any computer that can be started using a DOS floppy disk. Access to the drive's data is made on the physical level via the Basic Input-Output Subsystem (BIOS),...
252 KB  
Libraries  -  CAM::XML 1.14
CAM::XML is an encapsulation of a simple XML data structure. SYNOPSIS my $pollTag = CAM::XML->new(poll); foreach my $q (@questions) { my $questionTag = CAM::XML->new(question); $questionTag->add(-text => $q->{text}); my $choicesTag =...
22.53 KB  
Utilities  -  MISPBO Data Recovery 1.1
MISPBO Data Recovery allows you to recover your lost files, no matter how they were deleted. Using powerful bit-by-bit scanning methods, you can be sure to get your files back quickly and easily.
1.44 MB  
Utilities  -  Ultimate Data Recovery 5.0
Ultimate Data Recovery allows you to recover your lost files, no matter how they were deleted. Using powerful bit-by-bit scanning methods, you can be sure to get your files back quickly and easily.
1.16 MB  
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