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

Encode::PerlIO 5.8.1

  Date Added: January 21, 2010  |  Visits: 853

Encode::PerlIO

Report Broken Link
Printer Friendly Version


Product Homepage
Download (87 downloads)

Encode::PerlIO is a detailed document on Encode and PerlIO. Overview It is very common to want to do encoding transformations when reading or writing files, network connections, pipes etc. If Perl is configured to use the new perlio IO system then Encode provides a "layer" (see PerlIO) which can transform data as it is read or written. Here is how the blind poet would modernise the encoding: use Encode; open(my $iliad,<:encoding(iso-8859-7),iliad.greek); open(my $utf8,>:utf8,iliad.utf8); my @epic = < $iliad >; print $utf8 @epic; close($utf8); close($illiad); In addition, the new IO system can also be configured to read/write UTF-8 encoded characters (as noted above, this is efficient): open(my $fh,>:utf8,anything); print $fh "Any x{0021} string N{SMILEY FACE}n"; Either of the above forms of "layer" specifications can be made the default for a lexical scope with the use open ... pragma. See open. Once a handle is open, its layers can be altered using binmode. Without any such configuration, or if Perl itself is built using the systems own IO, then write operations assume that the file handle accepts only bytes and will die if a character larger than 255 is written to the handle. When reading, each octet from the handle becomes a byte-in-a-character. Note that this default is the same behaviour as bytes-only languages (including Perl before v5.6) would have, and is sufficient to handle native 8-bit encodings e.g. iso-8859-1, EBCDIC etc. and any legacy mechanisms for handling other encodings and binary data. In other cases, it is the programs responsibility to transform characters into bytes using the API above before doing writes, and to transform the bytes read from a handle into characters before doing "character operations" (e.g. lc, /W+/, ...). You can also use PerlIO to convert larger amounts of data you dont want to bring into memory. For example, to convert between ISO-8859-1 (Latin 1) and UTF-8 (or UTF-EBCDIC in EBCDIC machines): open(F, "<:encoding(iso-8859-1)", "data.txt") or die $!; open(G, ">:utf8", "data.utf") or die $!; while (< F >) { print G } # Could also do "print G < F >" but that would pull # the whole file into memory just to write it out again. More examples: open(my $f, "<:encoding(cp1252)") open(my $g, ">:encoding(iso-8859-2)") open(my $h, ">:encoding(latin9)") # iso-8859-15.

Requirements: No special requirements
Platforms: Linux
Keyword: Document Ebcdic Encode Encodeperlio Handle Libraries Open Perlio Print Programming Utf
Users rating: 0/10

License: Freeware Size: 11.3 MB
ENCODE::PERLIO RELATED
Libraries  -  Tie::Layers 0.06
SYNOPSIS ##### # Subroutines # use Tie::Layers qw(is_handle config); $yes = is_handle( $file_handle ); ($key, $old_value) = config(%options, $key); ($key, $old_value) = config(%options, $key => $new_value ); #### # Config default...
71.68 KB  
Database Tools  -  Get Hyperlink to Help Browser Page 1.0
Provide HREF text for Hyperlink to a Help Page Document Grabs the document link from the page currently open in the MATLAB Help Browser (doc). HTML text can be provided in MATLAB help pages for functions. This is useful when a specific help page...
10 KB  
File Utilities  -  McDwiff 1.1
McDwiff... DWF. Mac-style. Open, view, print, and convert Autodesk DWF files with this easy-to-use Mac application.Free for non-commercial use, $39 for commercial license.
87 KB  
Science  -  EpochX 1.4.1
EpochX is an open source genetic programming framework, specifically for analysing the properties of evolutionary automatic programming. It supports 3 popular representations - Strongly-Typed GP, Context-Free Grammar GP and Grammatical Evolution.
19.81 MB  
Utilities  -  Lx-Viewer 1.0.2
LX-Viewer is a program that will allow you to open, view, print and convert DWG or DXF files, typically used in AutoCAD related technical drafting. The most important feature is that LX-Viewer allows you to manipulate your DWG data on the Linux...
706.56 KB  
Finance  -  Document Convert 1.7 Build 5.27
Document Convert is an application that will help you convert documents from different directories into another file format. Supported the most popular document formats including MS Word files, Open Office, RTF, MS Write, Word Perfect, e-book...
 
Video Editors  -  Open Inventor 2.1.5
Open InventorTM is an object-oriented 3D toolkit offering a comprehensive solution to interactive graphics programming problems. It presents a programming model based on a 3D scene database that dramatically simplifies graphics programming. It...
7.9 MB  
Libraries  -  DynaPage::Document::ext::include 0.10
DynaPage::Document::ext::include module contains extensions of DynaPag::Document. METHODS template ( $self, $job ) : bool syntax: !include.template =- B See also DynaPage::Template NOTE: $self is parent document object (eg...
4.1 KB  
Programming  -  hexdump 1.6
hexdump produces a CP/M-like format by default, and can handle EBCDIC. It is internationalized, and has many formatting functions. This hex dumper was born because a) od octal format is appallingly ugly b) od -x aint much better c) I needed...
16.38 KB  
Libraries  -  Number::Encode 1.00
Number::Encode is a Perl module to encode bit strings into digit strings. SYNOPSIS use Number::Encode qw(nonuniform uniform); Provides a mechanism to convert arbitrary bit-strings into numeric digit strings. The transformation can be uniform...
2.05 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