ClientApi::SetProg( const StrPtr * )

Sets the application or script name for this connection.

Virtual?

No

 

Class

ClientApi

 

Arguments

const StrPtr *c

the new program name

Returns

void

 

Notes

SetProg() sets the identity of a client application as reported by the p4 monitor command, or as recorded by server logging.

Call SetProg() before calling Init().

See also

ClientApi::SetVersion()

Example

The following example appears as MyApp in the output of p4 monitor show.

ClientApi client;
ClientUser ui;
StrBuf sb;
Error e;

sb.Set( "MyApp" );

client.Init( &e );
client.SetProg( &sb );
client.Run( "info", &ui );