Description
CLIP provides a number of functions that can identify the type of process (ie. Master, Slave). These allow the code to make processing decisions dependent on the process. They can be called anywhere in the code, but are usually called in OnPrestart to initialise any Run-Time Attributes.
Generation
The ClpAmSlave function identifies whether this process is a Slave process
Uns ClpAmSlave();
Return
The function returns TRUE if this is a Slave process, FALSE otherwise.
Examples
bool MyProc1Process::OnPrestart()
{
...
if ( ClpAmAutonomous() )
gMEMORY = MB( 1024 );
else if ( ClpAmRootMaster() )
gMEMORY = MB( 512 );
else if ( ClpAmSubMaster() )
gMEMORY = MB( 512 );
else if ( ClpAmSlave() )
gMEMORY = MB( 1024 );
...
}