Function CDM_ReconstructAttribute


Definition:#include <CDM.h>
Prototype:CDM_Attribute CDM_ReconstructAttribute(CDM_Attribute Attribute);
Arguments:

Attribute: The Attribute object that is to be reconstucted. (CDM_Attribute)


Prototype:CDM_Attribute CDM_ReconstructAttribute(CDM_Attribute Attribute, int *type);
Arguments:

Attribute: The Attribute object that is to be reconstucted. (CDM_Attribute)
type: A pointer to an integer, where the type of the Attribute value will be stored. (int *)

C/C++ API Sections
Tcl API Sections
Description
Return Value
Notes
See Also
Index

Description:

CDM_Attribute CDM_ReconstructAttribute(CDM_Attribute Attribute):
This function accepts as argument a valid Attribute object (of type CDM_Attribute). This function will construct and return a new Attribute object that will be an exact copy of the provided one. The only difference will be that the returned Attribute object will utilise elements from the object cache that is managed internally by CDM. As a result the returned object will normally require less memory to be stored than the provided one, as it will re-use elements already in use by other CDM objects.

This function should be used on Attribute objects that originate from an unknown source. For example, if an Attribute object is stored in a file and then red back as a string, it will not use cached by the CDM objects. It will be a good idea if the caller created a new object by calling this function and delete the object red from the file by either calling Tcl_DecrRefCount or CDM_Free.

CDM_Attribute CDM_ReconstructAttribute(CDM_Attribute Attribute, int *type):
This function accepts as argument a valid Attribute object (of type CDM_Attribute). This function will construct and return a new Attribute object that will be an exact copy of the provided one. The only difference will be that the returned Attribute object will utilise elements from the object cache that is managed internally by CDM. As a result the returned object will normally require less memory to be stored than the provided one, as it will re-use elements already in use by other CDM objects.

This function should be used on Attribute objects that originate from an unknown source. For example, if an Attribute object is stored in a file and then red back as a string, it will not use cached by the CDM objects. It will be a good idea if the caller created a new object by calling this function and delete the object red from the file by either calling Tcl_DecrRefCount or CDM_Free.

Return Value:

CDM_Attribute CDM_ReconstructAttribute(CDM_Attribute Attribute):
This function returns a new Attribute object (of type CDM_Attribute) that is an exact copy of the porvided Attribute object, but requires less memory due to re-using cached objects.

In case of an error (i.e. the specified object is not a valid Attribute object) NULL will be returned and an error message will be left at the current active interpreter (CDM_Interp).

The returned object is not property of CDM and the caller is responsible to free this object when it is no longer needed by either calling Tcl_DecrRefCount or CDM_Free.

CDM_Attribute CDM_ReconstructAttribute(CDM_Attribute Attribute, int *type):
This function returns a new Attribute object (of type CDM_Attribute) that is an exact copy of the porvided Attribute object, but requires less memory due to re-using cached objects.

In the provided integer pointer, the Type of the Attribute value will be stored, if not NULL.

In case of an error (i.e. the specified object is not a valid Attribute object) NULL will be returned and an error message will be left at the current active interpreter (CDM_Interp).

The returned object is not property of CDM and the caller is responsible to free this object when it is no longer needed by either calling Tcl_DecrRefCount or CDM_Free.

Notes:

CDM_Attribute CDM_ReconstructAttribute(CDM_Attribute Attribute):
This function is equivelant to tip_ReconstructAttribute (Tcl API).

CDM_Attribute CDM_ReconstructAttribute(CDM_Attribute Attribute, int *type):
This function is equivelant to tip_ReconstructAttribute (Tcl API).

See Also:

CDM_Attribute CDM_ReconstructAttribute(CDM_Attribute Attribute):
CDM_ReconstructAnnotation, CDM_Free, Tcl_DecrRefCount, tip_ReconstructAttribute

CDM_Attribute CDM_ReconstructAttribute(CDM_Attribute Attribute, int *type):
CDM_ReconstructAnnotation, CDM_Free, Tcl_DecrRefCount, tip_ReconstructAttribute


Generated by: petasis@aias on Wed Aug 16 10:31:57 PM EEST 2006.