Net::FastCGI::Header - Object representation of a FCGI_Header
FCGI_Header
# Constructors $header = Net::FastCGI::Header->new($type, $request_id); $header = Net::FastCGI::Header->new($type, $request_id, $content_length); $header = Net::FastCGI::Header->new($type, $request_id, $content_length, $padding_length); $header = Net::FastCGI::Header->parse($octets); # Methods $octets = $header->build; $type = $header->get_type; $request_id = $header->get_request_id; $content_length = $header->get_content_length; $padding_length = $header->get_padding_length; $boolean = $header->has_content; $boolean = $header->has_padding; $string = $header->to_string;
Constructs an instance of Net::FastCGI::Header.
Net::FastCGI::Header
Usage
$header = Net::FastCGI::Header->new($type, $request_id); $header = Net::FastCGI::Header->new($type, $request_id, $content_length); $header = Net::FastCGI::Header->new($type, $request_id, $content_length, $padding_length);
Arguments
$type
An unsigned 8-bit integer.
$request_id
An unsigned 16-bit integer.
$content_length
An unsigned 16-bit integer. Defaults to 0.
0
$padding_length
An unsigned 8-bit integer. Defaults to compute_padding_length($content_length).
compute_padding_length($content_length)
Returns
$header
An instance of Net::FastCGI::Header.
Parses a FCGI_Header.
$header = Net::FastCGI::Header->parse($octets);
$octets
A string of octets containing the header, must be greater than or equal to 8 octets in length.
$octets = $header->build;
A string of octets containing the header. String is 8 octets in length.
$type = $header->get_type;
$request_id = $header->get_request_id;
$content_length = $header->get_content_length;
$padding_length = $header->get_padding_length;
$boolean = $header->has_content;
$boolean
A boolean indicating whether or not record has content.
$boolean = $header->has_padding;
A boolean indicating whether or not record has padding.
$string = $header->to_string;
$string
An ASCII string suitable for human consumption.
None.
Christian Hansen chansen@cpan.org
chansen@cpan.org
Copyright (c) 2008 Christian Hansen. All rights reserved.
This program is free software, you can redistribute it and/or modify it under the same terms as Perl itself.
To install Net::FastCGI, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Net::FastCGI
CPAN shell
perl -MCPAN -e shell install Net::FastCGI
For more information on module installation, please visit the detailed CPAN module installation guide.