.TH "RSL Memory Management" 3 "Wed Jan 25 2012" "Version 9.1" "globus rsl" \" -*- nroff -*- .ad l .nh .SH NAME RSL Memory Management \- .SS "Functions" .in +1c .ti -1c .RI "globus_rsl_t * \fBglobus_rsl_copy_recursive\fP (globus_rsl_t *ast_node)" .br .ti -1c .RI "globus_rsl_value_t * \fBglobus_rsl_value_copy_recursive\fP (globus_rsl_value_t *globus_rsl_value_ptr)" .br .ti -1c .RI "int \fBglobus_rsl_value_free\fP (globus_rsl_value_t *val)" .br .ti -1c .RI "int \fBglobus_rsl_free\fP (globus_rsl_t *ast_node)" .br .ti -1c .RI "int \fBglobus_rsl_value_free_recursive\fP (globus_rsl_value_t *globus_rsl_value_ptr)" .br .ti -1c .RI "int \fBglobus_rsl_free_recursive\fP (globus_rsl_t *ast_node)" .br .ti -1c .RI "int \fBglobus_rsl_value_list_literal_replace\fP (globus_list_t *value_list, char *string_value)" .br .ti -1c .RI "int \fBglobus_rsl_value_eval\fP (globus_rsl_value_t *ast_node, globus_symboltable_t *symbol_table, char **string_value, int rsl_substitution_flag)" .br .ti -1c .RI "int \fBglobus_rsl_eval\fP (globus_rsl_t *ast_node, globus_symboltable_t *symbol_table)" .br .in -1c .SH "Function Documentation" .PP .SS "globus_rsl_t* \fBglobus_rsl_copy_recursive\fP (globus_rsl_t *ast_node)" .PP Create a deep copy of an RSL syntax tree\&. The \fBglobus_rsl_copy_recursive()\fP function performs a deep copy of the RSL syntax tree pointed to by the \fIast_node\fP parameter\&. All RSL nodes, value nodes, variable names, attributes, and literals will be copied to the return value\&. .PP \fBParameters:\fP .RS 4 \fIast_node\fP An RSL syntax tree to copy\&. .RE .PP \fBReturns:\fP .RS 4 The \fBglobus_rsl_copy_recursive()\fP function returns a copy of its input parameter that that can be used after the \fIast_node\fP and its values have been freed\&. If an error occurs, \fBglobus_rsl_copy_recursive()\fP returns NULL\&. .RE .PP .SS "globus_rsl_value_t* \fBglobus_rsl_value_copy_recursive\fP (globus_rsl_value_t *globus_rsl_value_ptr)" .PP Create a deep copy of an RSL value\&. The \fBglobus_rsl_value_copy_recursive()\fP function performs a deep copy of the RSL value pointed to by the \fIglobus_rsl_value_ptr\fP parameter\&. All variable names, attributes, literals, and value lists will be copied to the return value\&. .PP \fBParameters:\fP .RS 4 \fIglobus_rsl_value_ptr\fP A pointer to an RSL value to copy\&. .RE .PP \fBReturns:\fP .RS 4 The \fBglobus_rsl_value_copy_recursive()\fP function returns a copy of its input parameter that that can be used after the \fIglobus_rsl_value_ptr\fP and its values have been freed\&. If an error occurs, \fBglobus_rsl_value_copy_recursive()\fP returns NULL\&. .RE .PP .SS "int \fBglobus_rsl_value_free\fP (globus_rsl_value_t *val)" .PP Free an RSL value node\&. The \fBglobus_rsl_value_free()\fP function frees the RSL value pointed to by the \fIval\fP parameter\&. This only frees the RSL value node itself, and not any sequence or string values associated with that node\&. .PP \fBParameters:\fP .RS 4 \fIval\fP The RSL value node to free\&. .RE .PP \fBReturns:\fP .RS 4 The \fBglobus_rsl_value_free()\fP function always returns GLOBUS_SUCCESS\&. .RE .PP .SS "int \fBglobus_rsl_free\fP (globus_rsl_t *ast_node)" .PP Free an RSL syntax tree node\&. The \fBglobus_rsl_free()\fP function frees the RSL syntax tree node pointed to by the \fIast_node\fP parameter\&. This only frees the RSL syntax tree node itself, and not any boolean operands, relation names, or values associated with the node\&. .PP \fBParameters:\fP .RS 4 \fIast_node\fP The RSL syntax tree node to free\&. .RE .PP \fBReturns:\fP .RS 4 The \fBglobus_rsl_value_free()\fP function always returns GLOBUS_SUCCESS\&. .RE .PP .SS "int \fBglobus_rsl_value_free_recursive\fP (globus_rsl_value_t *globus_rsl_value_ptr)" .PP Free an RSL value and all its child nodes\&. The \fBglobus_rsl_free_recursive()\fP function frees the RSL value node pointed to by the \fIglobus_rsl_value_ptr\fP, including all literal strings, variable names, and value sequences\&. Any pointers to these are no longer valid after \fBglobus_rsl_value_free_recursive()\fP returns\&. .PP \fBParameters:\fP .RS 4 \fIglobus_rsl_value_ptr\fP An RSL value node to free\&. .RE .PP \fBReturns:\fP .RS 4 The \fBglobus_rsl_value_free_recursive()\fP function always returns GLOBUS_SUCCESS\&. .RE .PP .SS "int \fBglobus_rsl_free_recursive\fP (globus_rsl_t *ast_node)" .PP Free an RSL syntax tree and all its child nodes\&. The \fBglobus_rsl_free_recursive()\fP function frees the RSL syntax tree pointed to by the \fIast_node\fP parameter, including all boolean operands, attribute names, and values\&. Any pointers to these are no longer valid after \fBglobus_rsl_free_recursive()\fP returns\&. .PP \fBParameters:\fP .RS 4 \fIast_node\fP An RSL parse tree to free\&. .RE .PP \fBReturns:\fP .RS 4 The \fBglobus_rsl_value_free_recursive()\fP function always returns GLOBUS_SUCCESS\&. .RE .PP .SS "int \fBglobus_rsl_value_list_literal_replace\fP (globus_list_t *value_list, char *string_value)" .PP Replace the first value in a value list with a literal\&. The \fBglobus_rsl_value_list_literal_replace()\fP function replaces the first value in the list pointed to by the \fIvalue_list\fP parameter with a new value node that is a literal string node pointing to the value of the \fIstring_value\fP parameter, freeing the old value\&. .PP \fBParameters:\fP .RS 4 \fIvalue_list\fP The RSL value list to modify by replacing its first element\&. .br \fIstring_value\fP The new string value to use as a literal first element of the list pointed to by the \fIvalue_list\fP parameter\&. .RE .PP \fBReturns:\fP .RS 4 Upon success, \fBglobus_rsl_value_list_literal_replace()\fP returns \fIGLOBUS_SUCCESS\fP, frees the current first value of \fIvalue_list\fP and replaces it with a new literal string node pointing to the value of the \fIstring_value\fP parameter\&. If an error occurs, \fBglobus_rsl_value_list_literal_replace()\fP returns 1\&. .RE .PP .SS "int \fBglobus_rsl_value_eval\fP (globus_rsl_value_t *ast_node, globus_symboltable_t *symbol_table, char **string_value, intrsl_substitution_flag)" .PP Evaluate RSL substitions in an RSL value node\&. The \fBglobus_rsl_value_eval()\fP function modifies the value pointed to by its \fIast_node\fP parameter by replacing all RSL substitution variable reference nodes with the literal values those variables evaluate to based on the current scope of the symbol table pointed to by the \fIsymbol_table\fP parameter\&. It also combines string concatenations into literal string values\&. Any nodes which are replaced by this function are freed using \fBglobus_rsl_value_free_recursive()\fP\&. .PP \fBParameters:\fP .RS 4 \fIast_node\fP A pointer to the RSL value node to evaluate\&. .br \fIsymbol_table\fP A symbol table containing current definitions of the RSL substitutions which can occur in this evaluation scope\&. .br \fIstring_value\fP An output parameter which is set to point to the value of the string returned by evaluating the value node pointed to by \fIast_node\fP if it evaluates to a literal value\&. list pointed to by the \fIvalue_list\fP parameter\&. .br \fIrsl_substitution_flag\fP A flag indicating whether the node pointed to by the \fIast_node\fP parameter defines RSL substition variables\&. .RE .PP \fBReturns:\fP .RS 4 Upon success, \fBglobus_rsl_value_eval()\fP returns \fIGLOBUS_SUCCESS\fP, and replaces any RSL substitution values in the node pointed to by the \fIast_node\fP parameter\&. If the node evaluates to a single literal, the \fIstring_value\fP parameter is modified to point to the value of that literal\&. If an error occurs, \fBglobus_rsl_value_eval()\fP returns a non-zero value\&. .RE .PP .SS "int \fBglobus_rsl_eval\fP (globus_rsl_t *ast_node, globus_symboltable_t *symbol_table)" .PP Evaluate an RSL syntax tree\&. The \fBglobus_rsl_eval()\fP function modifies the RSL parse tree pointed to by its \fIast_node\fP parameter by replacing all RSL substitution variable reference nodes with the literal values those variables evaluate to based on the current scope of the symbol table pointed to by the \fIsymbol_table\fP parameter\&. It also combines string concatenations into literal string values\&. Any nodes which are replaced by this function are freed using \fBglobus_rsl_value_free_recursive()\fP\&. .PP \fBParameters:\fP .RS 4 \fIast_node\fP A pointer to the RSL syntax tree to evaluate\&. .br \fIsymbol_table\fP A symbol table containing current definitions of the RSL substitutions which can occur in this evaluation scope\&. .RE .PP \fBReturns:\fP .RS 4 Upon success, \fBglobus_rsl_eval()\fP returns \fIGLOBUS_SUCCESS\fP, and replaces all RSL substitution values and concatenations in \fIast_node\fP or its child nodes with the evaluated forms described above\&. If an error occurs, \fBglobus_rsl_eval()\fP returns a non-zero value\&. .RE .PP .SH "Author" .PP Generated automatically by Doxygen for globus rsl from the source code\&.