IDLitParameter::QueryParameter
Syntax | Return Value | Arguments | Keywords | Example | Version History | See Also
The IDLitParameter::QueryParameter function method checks whether a parameter is registered, or retrieves a list of the names of all registered parameters.
Syntax
Result = Obj->[IDLitParameter::]QueryParameter([ParamName] [, COUNT=variable])
Return Value
If ParamName is a scalar string, this function returns a 1 if ParamName corresponds to a valid registered parameter, or a 0 otherwise. If ParamName is an array, the result is an array of 1s and 0s. If ParamName is not specified, Result is a string array containing the names of all registered parameters.
Arguments
ParamName
A scalar string or string array containing parameter names. If ParamName is not supplied, this function returns a list of all registered parameters.
Keywords
COUNT
Set this keyword equal to a named variable that will contain the number of parameters in Result. If ParamName is not supplied, then COUNT contains the number of registered parameters. If ParamName is supplied then COUNT contains the total number of matched parameters.
Example
This example creates an iPlot tool and tests whether a the plot visualization has a registered parameter named "vertices":
IPLOT, RANDOMU(seed, 15) idTool = IGETCURRENT(TOOL=otool) idPlot = oTool->FindIdentifiers('*plot*', /VISUALIZATIONS) oPlot = oTool->GetByIdentifier(idPlot) PRINT, oPlot->QueryParameter('vertices')
IDL prints:
Continuing the same example, we now query for the names of all parameters of the plot visualization:
IDL prints:
Version History
See Also
IDLitParameter::GetParameter, IDLitParameter::GetParameterAttribute, IDLitParameter::RegisterParameter, IDLitParameter::SetParameterAttribute