(Page 6 of 9 in this chapter)
3.5 Managing Parameters
The characteristics for CT Access services can be altered by modifying associated parameters. Parameters are grouped together in C language structures called parameter structures. Each parameter structure has default values that are sufficient for most configurations. The parameters can be modified to enable/disable features and to adapt the service for special configurations.
CT Access knows how to store and retrieve the values of named parameters and structures for any service. All services providing the same functionality have the same
standard
parameters. Services providing the same functionality but implemented on different hardware may have unique
extension
parameters.
In addition to CT Access named parameters, most service API functions allow the application to pass a data structure to override all the parameters.
3.5.1 Parameter Scope
CT Access stores two copies of service parameters:
Global default parameters
CTA context default parameters
When CT Access is initialized via
ctaInitialize
, the service descriptors and values are created and stored. These are the global default parameters.
When a service is opened on a CTA context, the global default parameters are copied into the CTA context. The CTA context default parameters may then be modified to define context characteristics.
You can also refresh the CTA context parameters with the global default values as needed.
Figure 23. Parameter Scope
3.5.2 Global Default Parameters
As specified in
ctaInitialize
, CT Access uses either process local memory or system shared memory to store the global default parameters.
If default parameters are shared among processes using system shared memory, then the CT Access process daemon (
ctdaemon
)
must be running. In this case, the parameter values can be modified by a configuration file.
The daemon process is launched with the file name containing changes to the defaults. The daemon creates the shared memory with the parameters and modifies the defaults. Applications subsequently launched can use the shared memory as the global defaults.
Figure 24. System Global Default Parameters
If process local memory is used, configuration of the global default parameters only affects process values. In this case, only the CT Access parameter functions can be used to modify the global default parameters.
Figure 25. Process Global Default Parameters
3.5.3 Parameter Functions
The following table lists the parameter functions. If a valid CTA context handle (
ctahd
) is passed to the function, the CTA context copy of the parameters are retrieved or modified. If the CTA context passed is
NULL_CTAHD
, the global default values are retrieved or modified.
If you want to...
Then use this function...
Modify a single field for a given parameter name
ctaSetParmByName
Retrieve a single field for a given parameter name
ctaGetParmByName
Retrieve a parameter field definition
ctaGetParmInfo
Return parameter values for a given parameter structure
ctaGetParms
Reset values of all context parameters on a CTA context to the global defaults
ctaRefreshParms
The
ctaparm
utility displays system parameter defaults. Refer to
Section 13.3.1,
CT Access Parameter Display: ctaparm
for more information.
The
ctdaemon
utility allows you to modify system global default parameters and set the global tracemask. Refer to
Section 13.3.3,
CT Access Daemon: ctdaemon
for more information.
(Page 6 of 9 in this chapter)
Tech_Support@nmss.com
Copyright © 1996, Natural MicroSystems, Inc. All rights reserved.