Table of Contents
Preface: About This Manual
-
Please give us feedback
Chapter 1: Overview
-
Release compatibility of the API
-
Purpose of the API
-
Architecture of the API
-
API files
Chapter 2: Client Programming
-
Compiling and linking client programs
-
Link order
-
Compiler support
-
Sample Jamfile
-
Sample Makefile
-
Building with Jam
-
Building the sample application
-
Sending commands to the server
-
Perforce settings on the client machine
-
Connecting to the server
-
Displaying Perforce forms
-
Sending commands
-
Processing data from the server
-
Disconnecting from the server
-
Performing file I/O
-
Handling errors
-
Connection errors
-
Server errors
-
Class overviews
-
ClientApi - Perforce server connections and commands
-
ClientUser - I/O for Perforce commands
-
Error - collect and report layered errors
-
ErrorLog - output error messages
-
FileSys - Perforce file I/O
-
KeepAlive - support for client-side disconnection
-
Options - parse and store command line options
-
Signaler - interrupt handling
-
StrBuf - string manipulation
-
StrDict - field/value manipulation
-
StrNum - small numeric strings
-
StrOps - string operations
-
StrPtr - text operations
-
StrRef - refer to existing strings
Chapter 3: Public Methods Reference
-
ClientApi methods
-
ClientApi::DefineClient( const char *, Error * )
-
ClientApi::DefineHost( const char *, Error * )
-
ClientApi::DefinePassword( const char *, Error * )
-
ClientApi::DefinePort( const char *, Error * )
-
ClientApi::DefineUser( const char *, Error * )
-
ClientApi::Dropped( )
-
ClientApi::Final( Error * )
-
ClientApi::GetClient( )
-
ClientApi::GetCwd( )
-
ClientApi::GetConfig( )
-
ClientApi::GetHost( )
-
ClientApi::GetOs( )
-
ClientApi::GetPassword( )
-
ClientApi::GetPort( )
-
ClientApi::GetProtocol( const char * )
-
ClientApi::GetUser( )
-
ClientApi::Init( Error * )
-
ClientApi::Run( const char * )
-
ClientApi::RunTag( const char *, ClientUser * )
-
ClientApi::SetBreak( KeepAlive *breakCallback )
-
ClientApi::SetClient( const StrPtr * )
-
ClientApi::SetClient( const char * )
-
ClientApi::SetCwd( const StrPtr * )
-
ClientApi::SetCwd( const char * )
-
ClientApi::SetHost( const StrPtr * )
-
ClientApi::SetHost( const char * )
-
ClientApi::SetPassword( const StrPtr * )
-
ClientApi::SetPassword( const char * )
-
ClientApi::SetPort( const StrPtr * )
-
ClientApi::SetPort( const char * )
-
ClientApi::SetProg( const StrPtr * )
-
ClientApi::SetProg( const char * )
-
ClientApi::SetProtocol( char *, char * )
-
ClientApi::SetProtocolV( char * )
-
ClientApi::SetTicketFile( const StrPtr * )
-
ClientApi::SetTicketFile( const char * )
-
ClientApi::SetUser( const StrPtr * )
-
ClientApi::SetUser( const char * )
-
ClientApi::SetVersion( const StrPtr * )
-
ClientApi::SetVersion( const char * )
-
ClientApi::WaitTag( ClientUser * )
-
ClientUser methods
-
ClientUser::Diff( FileSys *, FileSys *, int, char *, Error * )
-
ClientUser::Edit( FileSys *, Error * )
-
ClientUser::ErrorPause( char *, Error * )
-
ClientUser::File( FileSysType )
-
ClientUser::Finished( )
-
ClientUser::HandleError( Error * )
-
ClientUser::Help( const_char * const * )
-
ClientUser::InputData( StrBuf *, Error * )
-
ClientUser::Merge( FileSys *, FileSys *, FileSys *, FileSys *, Error * )
-
ClientUser::Message( Error * )
-
ClientUser::OutputBinary( const_char *, int )
-
ClientUser::OutputError( const_char * )
-
ClientUser::OutputInfo( char, const_char * )
-
ClientUser::OutputStat( StrDict* )
-
ClientUser::OutputText( const_char *, int )
-
ClientUser::Prompt( const StrPtr &, StrBuf &, int, Error * )
-
ClientUser::RunCmd( const char *, const char *, [...], Error * )
-
Error methods
-
Error::Clear( )
-
Error::Dump( const char * )
-
Error::Fmt( StrBuf * )
-
Error::Fmt( StrBuf * , int )
-
Error::GetGeneric( )
-
Error::GetSeverity( )
-
Error::IsFatal( )
-
Error::IsWarning( )
-
Error::Net( const char *, const char * )
-
Error::operator << ( int )
-
Error::operator << ( char * )
-
Error::operator << ( const StrPtr & )
-
Error::operator = ( Error & )
-
Error::Set( enum ErrorSeverity, const char * )
-
Error::Set( ErrorId & )
-
Error::Sys( const char *, const char * )
-
Error::Test( )
-
ErrorLog methods
-
ErrorLog::Abort()
-
ErrorLog::Report( )
-
ErrorLog::SetLog( const char * )
-
ErrorLog::SetSyslog( )
-
ErrorLog::SetTag( const char * )
-
ErrorLog::UnsetSyslog( )
-
FileSys methods
-
FileSys::Chmod( FilePerm, Error * )
-
FileSys::Close( Error * )
-
FileSys::Create( FileSysType )
-
FileSys::Open( FileOpenMode, Error * )
-
FileSys::Read( const char *, int, Error * )
-
FileSys::Rename( FileSys *, Error * )
-
FileSys::Set( const StrPtr * )
-
FileSys::Stat( )
-
FileSys::StatModTime( )
-
FileSys::Truncate( )
-
FileSys::Unlink( Error * )
-
FileSys::Write( const char *, int, Error * )
-
KeepAlive methods
-
KeepAlive::IsAlive( )
-
Options methods
-
Options::GetValue( char opt, int subopt )
-
Options::operator[]( char opt )
-
Options::Parse(int&,char**&,const char*,int,const ErrorId&, Error*)
-
Options::Parse(int&,StrPtr*&,const char*,int,const ErrorId&, Error*)
-
Signaler methods
-
Signaler::Block( )
-
Signaler::Catch( )
-
Signaler::DeleteOnIntr( void* )
-
Signaler::Intr( )
-
Signaler::OnIntr( SignalFunc, void* )
-
Signaler::Signaler( ) (constructor)
-
StrBuf methods
-
StrBuf::Alloc( int )
-
StrBuf::Append( const char * )
-
StrBuf::Append( const char *, int )
-
StrBuf::Append( const StrPtr * )
-
StrBuf::Clear( )
-
StrBuf::StrBuf( )(Constructor)
-
StrBuf::StrBuf( const StrBuf & )(Copy Constructor)
-
StrBuf::~StrBuf( )(Destructor)
-
StrBuf::Extend( char )
-
StrBuf::Extend( const char *, int )
-
StrBuf::operator =( const char * )
-
StrBuf::operator =( const StrBuf & )
-
StrBuf::operator =( const StrPtr & )
-
StrBuf::operator =( const StrRef & )
-
StrBuf::operator <<( const char * )
-
StrBuf::operator <<( int )
-
StrBuf::operator <<( const StrPtr * )
-
StrBuf::operator <<( const StrPtr & )
-
StrBuf::Set( const char * )
-
StrBuf::Set( const char *, int )
-
StrBuf::Set( const StrPtr * )
-
StrBuf::Set( const StrPtr & )
-
StrBuf::StringInit( )
-
StrBuf::Terminate( )
-
StrDict methods
-
StrDict::GetVar( const StrPtr & )
-
StrDict::GetVar( const char * )
-
StrDict::GetVar( const char *, Error * )
-
StrDict::GetVar( const StrPtr &, int )
-
StrDict::GetVar( const StrPtr &, int, int )
-
StrDict::GetVar( int, StrPtr &, StrPtr & )
-
StrDict::Load( FILE *)
-
StrDict::Save( FILE * )
-
StrDict::SetArgv( int, char *const * )
-
StrNum methods
-
StrNum::Set( int )
-
StrOps methods
-
StrOps::Caps( StrBuf & )
-
StrOps::Dump( const StrPtr & )
-
StrOps::Expand( StrBuf &, StrPtr &, StrDict & )
-
StrOps::Expand2( StrBuf &, StrPtr &, StrDict & )
-
StrOps::Indent( StrBuf &, const StrPtr & )
-
StrOps::Lines( StrBuf &, char *[], int )
-
StrOps::Lower( StrBuf & )
-
StrOps::OtoX( const unsigned char *, int, StrBuf & )
-
StrOps::Replace(StrBuf&,const StrPtr&,const StrPtr&,const StrPtr&)
-
StrOps::Sub( StrPtr &, char, char )
-
StrOps::Words( StrBuf &, char *[], int )
-
StrOps::XtoO( char *, unsigned char *, int )
-
StrPtr methods
-
StrPtr::Atoi( )
-
StrPtr::CCompare( const StrPtr & )
-
StrPtr::Compare( const StrPtr & )
-
StrPtr::Contains( const StrPtr & )
-
StrPtr::Length( )
-
StrPtr::operator []( int )
-
StrPtr::operators ==, !=, >, <, <=, >= ( const char * )
-
StrPtr::operators ==, !=, >, <, <=, >= ( const StrPtr & )
-
StrPtr::Text( )
-
StrPtr::Value( )
-
StrPtr::XCompare( const StrPtr & )
-
StrRef methods
-
StrRef::StrRef( const StrPtr & ) (constructor)
-
StrRef::StrRef( const char * ) (constructor)
-
StrRef::StrRef( const char * , int ) (constructor)
-
StrRef::Null()
-
StrRef::operator =( StrPtr & )
-
StrRef::operator =( char * )
-
StrRef::operator +=( int )
-
StrRef::Set( char * )
-
StrRef::Set( char * , int )
-
StrRef::Set( const StrPtr * )
-
StrRef::Set( const StrPtr & )
This manual copyright 2002-2005 Perforce Software.
All rights reserved.
Perforce software and documentation is available from http://www.perforce.com. You may download and use Perforce programs, but you may not sell or redistribute them. You may download, print, copy, edit, and redistribute the documentation, but you may not sell it, or sell any documentation derived from it. You may not modify or attempt to reverse engineer the programs.
Perforce programs and documents are available from our Web site as is. No warranty or support is provided. Warranties and support, along with higher capacity servers, are sold by Perforce Software.
Perforce Software assumes no responsibility or liability for any errors or inaccuracies that may appear in this book.
By downloading and using our programs and documents you agree to these terms.
Perforce and Inter-File Branching are trademarks of Perforce Software. Perforce software includes software developed by the University of California, Berkeley and its contributors.
All other brands or product names are trademarks or registered trademarks of their respective companies or organizations.
Please send comments and questions about this manual to
[email protected].
Copyright 2002-2005 Perforce Software. All rights reserved.
Last updated: 12/15/05