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

Stream::Reader 0.09

  Date Added: October 04, 2010  |  Visits: 1.772

Stream::Reader

Report Broken Link
Printer Friendly Version


Product Homepage
Download (107 downloads)



Stream::Reader is a stream reader Perl class. SYNOPSIS # Input stream can be reference to TYPEGLOB or SCALAR, output stream # can be the same types or undefined # Constructor $stream = Stream::Reader->new( *IN, { Limit => $limit, BuffSize => $buffsize, Mode => UB } ); # Reading all before delimiter beginning from current position. # Delimiter is SCALAR or reference to array with many SCALARs. # Returns true value on succesfull matching or if end of stream # expected at first time $bool = $stream->readto( $delimiter, { Out => *OUT, Limit => $limit, Mode => AIE } ); # Reading fixed number of chars beginning from current position. # Returns true value if was readed number of chars more then zero or # end of stream was not expected yet $bool = $stream->readsome( $limit, { Out => *OUT, Mode => A } ); # Mode is string, what can contains: # U - modificator for constructor. disable utf-8 checking # B - modificator for constructor. enable second buffer for speed up # case insensitive search # A - modificator for readto() and readsome(). appending data to # output stream, if stream is SCALAR # I - modificator for readto(). enable case insensitive search # E - modificator for readto(). at end of input stream alltimes # returns false value $number = $stream->{Total}; # total number of readed chars $number = $stream->{Readed}; # number of readed chars at last # operation (without matched string # length at readto() method) $number = $stream->{Stored}; # number of succesfully stored chars # at last operation $string = $stream->{Match}; # matched string at last operation # (actually for readto() only) $bool = $stream->{Error}; # error status. true on error METHODS OBJ = Stream::Reader->new( INPUT, { ... Params ... } ) The constructor method instantiates a new Stream::Reader object. INPUT - is a reference to file stream, opened for reading, or reference to defined string. This is an obligatory parameter. Params (all optionaly): Limit - limit size of input stream data in characters. If this parameter is absent, not defined or less then zero, then all data from input stream will be available for reading. BuffSize - size of buffer in characters. If this parameter is absent, not defined or less then zero, then will be used default buffer size 32768 characters. Mode - is string with letters-modificators: B - use second buffer. Can really speed up search in case insensitive mode. U - disable UTF-8 data check in UTF-8 mode. Use this flag if you are absolutely sure, that your UTF-8 data is valid. RESULT = OBJ->readto( DELIMITER, { ... Params ... } ) This method reads all data from input stream before first found delimiter, beginning from current position. RESULT - boolean value. True value if successfuly found delimeter or and of input stream has expected at first time. False value otherwise, or in case of reading error. DELIMETER - is a string-delimeter or reference to array with many delimeters. This is an obligatory parameter and must be defined. Remember! In case of many delimiters, left delimiter alltimes have more priority then right! Params (all optionaly): Out - is a reference to file stream, opened for writing, or reference to string. If this parameter is absent then data will not stored. Limit - size in characters. Defines, the maximum number of characters that must be stored in Out. If this paramter is absent, not defined or less then zero, then this method will be trying to store all readed data. Mode - is string with letters-modificators: A - appendig data to Out if Out is a reference to string. I - search in case insensitive mode. E - at the end of input stream returns only false value. Without this modificator, if end of stream expected at first time, then will be returned true value. RESULT = OBJ->readsome( LIMIT, { ... Params ... } ) This method reads fixed number of characters from input stream beginning from current position. RESULT - boolean value. True value, if any characters were read or end of input stream is not expected yet. False value otherwise, or in case of reading error. LIMIT - limit size in characters, how many it is necessary to read. If this parameter is absent, not defined or less then zero, then will be read all available data from input stream. Params (all optionaly): Out - the same as in readto() method. Mode - is string with letters-modificators: A - the same as in readto() method. Statistics: OBJ->{Total} - total number of readed characters. Warning! This module using block reading and real position in stream is different. OBJ->{Readed} - number of readed characters at last operation (without matched string length at readto() method). OBJ->{Stored} - number of succesfully stored chars at last operation OBJ->{Match} - matched string at last operation (actually for readto() only) OBJ->{Error} - boolen error status. At any reading erorrs all operations will be stopes and this flag turned to true value..

Requirements: No special requirements
Platforms: Linux
Keyword: End Of End Of Input In Case In Case Of Input Stream Number Obj Reference To Result Scalar Stream Streamreader True Value Utf Will Be
Users rating: 0/10

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


STREAM::READER RELATED
Modules  -  Input stream 6.x-1.0
A temp stream is used to store the copied php://input stream.Only one temp stream is created regardless of how many drupal://input streams are openend, and it is safe to use the multiple drupal://input streams at the same time as the wrapper takes...
10 KB  
Audio Encoders & Decoders  -  Free iovSoft MP3 Cutter Joiner 3.06.09
Do you want to cut and get out the excellent part in an audio file? Do you want to join a lot of audio files into one file? Please test Free iovSoft MP3 Cutter Joiner. It will be your best choice. Free iovSoft MP3 Cutter Joiner consists of a...
2.66 MB  
Modules  -  GC-conversation 0.2
When someone uses "@pete", "@21" or "#pete", "#21" in a comment, GC-Conversation converts that reference to a link that opens a small pop-up containing the text of the referenced comment. For example: the Nth comment, or the last comment of the...
10 KB  
Modules  -  Dynamic Theme 5.x-1.x-dev 1.0
By setting the dynamic_theme Session variable to an installed theme, the site's theme will be that of the set variable until the variable is unset. This Session variable can be set by setting a link path from 'my/link/path' to...
 
Libraries  -  RTF::Writer 1.11
RTF::Writer is a Perl module for generating documents in Rich Text Format. SYNOPSIS use RTF::Writer; my $rtf = RTF::Writer->new_to_file("greetings.rtf"); $rtf->prolog( title => "Greetings, hyoomon" ); $rtf->number_pages; $rtf->paragraph(...
57.34 KB  
Arcade Style Games  -  Breakout in Space 4.0
The objective of the game is it to keep a ball in the game (with the help of your board) until all breakable game blocks are destroyed. With the mouse you can move the board left and right. The ball can be launched from the center of the board to...
1.13 MB  
Delphi Utilities  -  RxLIB 2.0
Set of components which will be estimated by any programmer, in particular RxRichEdit (with support BMP of maps). Components for operation with forms, databases, visualisation
1003.52 KB  
Games  -  Pile of Balls 1. 2. 2000
In this game there will be an area where you drop balls to pile them up. Each time 3 balls will be given and you can rotate or move them before dropping them to the group to pile them up. When 4 or more balls of the same colour are connected, the...
262 KB  
Networking Tools  -  Bait and Switch Honeypot System 2.1
The Bait and Switch Honeypot is a multifaceted attempt to take honeypots out of the shadows of the network security model and to make them an active participant in system defense. To do this, we are creating a system that reacts to hostile...
378.88 KB  
Form Processors  -  Multiply InPut By 1.1
This script allows you to multiply a 'source' text box value with a number and display the result in a 'result' text box.Any number of applications can exist on a page.
10 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