contents   index   previous   next



seInternalizeStringHidden

 

syntax:

   sestring

seInternalizeString(secontext se,

                    seconstcharptr string,

                    sememcount len);

   sestring

seInternalizeStringHidden(secontext se,

                    seconstcharptr string,

                    sememcount len);

where:

se the context to internalize the string into

 

string the text of the member name to internalize

 

len the length in characters (not bytes) of the string, or SE_IS_STRLEN to let seInternalizeString use strlen_sechar() to determine the length of the string.

 

return:

The internalized sestring

 

description:

All object member names are internalized by the ScriptEase engine before use. This API call is used to get the internalized version of a particular string. It is useful for commonly-used strings as whenever you use the text of the string, ScriptEase must internalize that string. In addition, ScriptEase internal strings can be directly compared using a single == comparison rather than the much slower strcmp_sechar.

 

The resulting sestring can be used as a member name using the SE_STR() member name specifier. In addition, object callbacks return sestring for the member name being accessed.

 

ScriptEase internal strings are always locked until explicitly freed. Use seFreeInternalString to indicate you are finished with a particular internal sestring. You can also duplicate an sestring using seCloneInternalString. Refer to the standard ScriptEase lifetime model, as internal strings follow that with the exception that no internal strings are freed automatically when a wrapper function exits.

 

The difference between seInternalizeString() and seInternalizeStringHidden() is that seInternalizeStringHidden() will create a property name that is not accesible from scripts (similar to SE_HIDDEN_MEM or SE_HIDDEN_UNIMEM).

 

see:

seCloneInternalString, seFreeInternalString, seGetInternalString

 


seCloneInternalString