Houdini Engine 3.5
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Environment

Functions

HAPI_DECL HAPI_GetEnvInt (HAPI_EnvIntType int_type, int *value)
 Gives back a certain environment integers like version number. Note that you do not need a session for this. These constants are hard-coded in all HAPI implementations, including HARC and HAPIL. This should be the first API you call to determine if any future API calls will mismatch implementation. More...
 
HAPI_DECL HAPI_GetSessionEnvInt (const HAPI_Session *session, HAPI_SessionEnvIntType int_type, int *value)
 Gives back a certain session-specific environment integers like current license type being used. More...
 
HAPI_DECL HAPI_GetServerEnvInt (const HAPI_Session *session, const char *variable_name, int *value)
 Get environment variable from the server process as an integer. More...
 
HAPI_DECL HAPI_GetServerEnvString (const HAPI_Session *session, const char *variable_name, HAPI_StringHandle *value)
 Get environment variable from the server process as a string. More...
 
HAPI_DECL HAPI_GetServerEnvVarCount (const HAPI_Session *session, int *env_count)
 Provides the number of environment variables that are in the server environment's process. More...
 
HAPI_DECL HAPI_GetServerEnvVarList (const HAPI_Session *session, HAPI_StringHandle *values_array, int start, int length)
 Provides a list of all of the environment variables in the server's process. More...
 
HAPI_DECL HAPI_SetServerEnvInt (const HAPI_Session *session, const char *variable_name, int value)
 Set environment variable for the server process as an integer. More...
 
HAPI_DECL HAPI_SetServerEnvString (const HAPI_Session *session, const char *variable_name, const char *value)
 Set environment variable for the server process as a string. More...
 

Detailed Description

Functions for reading and writing to the session environment

Function Documentation

HAPI_DECL HAPI_GetEnvInt ( HAPI_EnvIntType  int_type,
int *  value 
)

Gives back a certain environment integers like version number. Note that you do not need a session for this. These constants are hard-coded in all HAPI implementations, including HARC and HAPIL. This should be the first API you call to determine if any future API calls will mismatch implementation.

Parameters
[in]int_typeOne of HAPI_EnvIntType.
[out]valueInt value.
HAPI_DECL HAPI_GetServerEnvInt ( const HAPI_Session session,
const char *  variable_name,
int *  value 
)

Get environment variable from the server process as an integer.

Parameters
[in]sessionThe session of Houdini you are interacting with. See Sessions for more on sessions. Pass NULL to just use the default in-process session.
[in]variable_nameName of the environmnet variable.
[out]valueThe int pointer to return the value in.
HAPI_DECL HAPI_GetServerEnvString ( const HAPI_Session session,
const char *  variable_name,
HAPI_StringHandle value 
)

Get environment variable from the server process as a string.

Parameters
[in]sessionThe session of Houdini you are interacting with. See Sessions for more on sessions. Pass NULL to just use the default in-process session.
[in]variable_nameName of the environmnet variable.
[out]valueThe HAPI_StringHandle pointer to return the value in.
HAPI_DECL HAPI_GetServerEnvVarCount ( const HAPI_Session session,
int *  env_count 
)

Provides the number of environment variables that are in the server environment's process.

Parameters
[in]sessionThe session of Houdini you are interacting with. See Sessions for more on sessions. Pass NULL to just use the default in-process session.
[out]env_countA pointer to an int to return the value in
HAPI_DECL HAPI_GetServerEnvVarList ( const HAPI_Session session,
HAPI_StringHandle values_array,
int  start,
int  length 
)

Provides a list of all of the environment variables in the server's process.

Parameters
[in]sessionThe session of Houdini you are interacting with. See Sessions for more on sessions. Pass NULL to just use the default in-process session.
[out]values_arrayAn HAPI_StringHandle array at least the size of length
[in]startFirst index of range. Must be at least 0 and at most env_count returned by HAPI_GetServerEnvVarCount()
[in]lengthGiven env_count returned by HAPI_GetServerEnvVarCount(), length should be at least 0 and at most env_count - start.
HAPI_DECL HAPI_GetSessionEnvInt ( const HAPI_Session session,
HAPI_SessionEnvIntType  int_type,
int *  value 
)

Gives back a certain session-specific environment integers like current license type being used.

Parameters
[in]sessionThe session of Houdini you are interacting with. See Sessions for more on sessions. Pass NULL to just use the default in-process session.
[in]int_typeOne of HAPI_SessionEnvIntType.
[out]valueInt value.
HAPI_DECL HAPI_SetServerEnvInt ( const HAPI_Session session,
const char *  variable_name,
int  value 
)

Set environment variable for the server process as an integer.

Note that this may affect other sessions on the same server process. The session parameter is mainly there to identify the server process, not the specific session.

For in-process sessions, this will affect the current process's environment.

Parameters
[in]sessionThe session of Houdini you are interacting with. See Sessions for more on sessions. Pass NULL to just use the default in-process session.
[in]variable_nameName of the environment variable.
[in]valueThe integer value.
HAPI_DECL HAPI_SetServerEnvString ( const HAPI_Session session,
const char *  variable_name,
const char *  value 
)

Set environment variable for the server process as a string.

Note that this may affect other sessions on the same server process. The session parameter is mainly there to identify the server process, not the specific session.

For in-process sessions, this will affect the current process's environment.

Parameters
[in]sessionThe session of Houdini you are interacting with. See Sessions for more on sessions. Pass NULL to just use the default in-process session.
[in]variable_nameName of the environmnet variable.
[in]valueThe string value.