Thrift::Parser::Type - Base clase for OO types
Returns a reference to the Thrift::IDL::Type that informed the creation of this class.
Returns a reference to the Thrift::IDL object that this was formed from.
Returns the simple name of the type.
Returns the internal representation of the value of this object.
Boolean; is a value defined for this object.
my $object = $subclass->compose(..);
Returns a new object in the class/subclass namespace with the value given. Generally you may pass a simple perl variable or another object in this same class to create the new object. Throws Thrift::Parser::InvalidArgument or Thrift::Parser::InvalidTypedValue. See subclass documentation for more specifics.
Used internally. Overridden for complex type classes that require the IDL to inform their creation and schema (mainly Thrift::Parser::Type::Container).
my $object = $class->read($protocol);
Implemented in subclasses, this will create new objects from a Thrift::Protocol.
$object->write($protocol)
Given a Thrift::Protocol object, will write out this type to the buffer. Overridden in all most subclasses.
if ($object_a->equal_to($object_b)) { ... }
Performs an equality test between two blessed objects. You may also call with a non-blessed reference (a perl scalar, for instance), which will be passed to compose() to be formed into a proper object before the comparison is run. Throws Thrift::Parser::InvalidArgument.
compose()
Used internally for the "equal_to" call.
Implemented by the specific type.
Returns the Thrift type id. Overridden in subclasses. Throws Thrift::Parser::Exception.
Returns a POD formatted string that documents a derived class.
Copyright (c) 2009 Eric Waters and XMission LLC (http://www.xmission.com/). All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
The full text of the license can be found in the LICENSE file included with this module.
Eric Waters <ewaters@gmail.com>
To install Thrift::Parser, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Thrift::Parser
CPAN shell
perl -MCPAN -e shell install Thrift::Parser
For more information on module installation, please visit the detailed CPAN module installation guide.