David L. Armstrong > P4-OO-0.00_02 > P4::OO

Download:
P4-OO-0.00_02.tar.gz

Dependencies

Annotate this POD

Module Version: 0.00_02   Source  

NAME ^

P4::OO - First class objects for Perforce specs

SYNOPSIS ^

 # use P4PERL and P4PORT/P4CLIENT environment by default
 my $p4oo = P4::OO->new();

ENVIRONMENT ^

 P4::OO requires P4PERL to talk directly to Perforce

 P4::OO uses reasonable defaults, and using the caller's P4PORT
and P4CLIENT environment variables to find the Perforce client to use.

DESCRIPTION ^

 P4::OO is distinguished from P4PERL in that P4PERL provides a
handle for talking to Perforce in a manner similar to the 'p4'
command.  P4::OO represents Perforce specs as first class objects
(similar to type-specific versions of P4::Spec objects),
and provides capability for added functionality for each type of
object.

First Class Objects

 These objects are provided and corresspond directly to the 'p4'
subcommands by the same names:
 P4:OO::Branch
 P4:OO::Change
 P4:OO::Changelist - P4:OO::Change by another name.
 P4:OO::Client
 P4:OO::Depot
 P4:OO::Group
 P4:OO::Job
 P4:OO::Label
 P4:OO::User
 P4:OO::Workspace - P4:OO::Client by another name.

Connecting P4::OO to your Perforce database

 If you initialize your own P4PERL connection, you can have P4::OO
use it instead of constructing it's own.  You will also have to
disconnect it when you're done.  If P4:OO constructs it's
own P4PERL connection, P4::OO will also attempt to destroy it at
garbage collection time.

 # Connect to P4PERL and have have P4::OO reuse connection
 my $p4PerlObj = P4->new();
 $p4PerlObj->SetClient( $clientname );
 $p4PerlObj->SetPort ( $p4port );
 $p4PerlObj->Connect();

 # Initialize P4::OO with this P4PERL connection
 my $p4ooObj = P4::OO->new( 'p4PerlObj' => $p4PerlObj );

 # When you're done with P4::OO and your P4PERL connection
 $p4PerlObj->Disconnect();

SEE ALSO ^

 P4PERL - http://public.perforce.com/guest/tony_smith/perforce/API/Perl/index.html

AUTHOR ^

David L. Armstrong <armstd@cpan.org>

COPYRIGHT AND LICENSE ^

P4::OO is Copyright (c)2010-2011, David L. Armstrong.

 This module is free software; you can redistribute it and/or
modify it under the same terms as Perl itself, either Perl
version 5.8.8 or, at your option, any later version of Perl 5
you may have available.

SUPPORT AND WARRANTY ^

 This program is distributed in the hope that it will be
useful, but it is provided "as is" and without any expressed
or implied warranties.
syntax highlighting: