Adobe.com
Contents Suites Classes Class Index Member Index

SPStringsSuite Struct Reference
[API Suite List]

This suite allows you to work with the PICA string pool. More...

#include <SPStrngs.h>

List of all members.

Public Attributes

SPAPI SPErr(* AllocateStringPool )(SPStringPoolRef *stringPool)
 Creates a new string pool and allocates an initial block of memory for its strings.
SPAPI SPErr(* FreeStringPool )(SPStringPoolRef stringPool)
 Frees the memory used for a string pool created with AllocateStringPool().
SPAPI SPErr(* MakeWString )(SPStringPoolRef stringPool, const char *string, const char **wString)
 Adds a string to a string pool, or, if the string has already been added to the pool, retrieves a reference to the pooled string.

Detailed Description

This suite allows you to work with the PICA string pool.

PICA manages a string pool, which provides an efficient central storage space for C strings. When a string is placed in the pool, PICA checks whether it already exists in the pool, and if so, returns a pointer to the existing string. If not, it copies the string into the pool, and returns a pointer to the copy.

This mechanisms atomizes the strings. Because each string exists in only one place, strings can be compared by address, rather than character by character, and string searches are made much more efficient.


Member Data Documentation

Creates a new string pool and allocates an initial block of memory for its strings.

You can also access PICA's global string pool, using SPRuntimeSuite::GetRuntimeStringPool().

Parameters:
stringPool [out] A buffer in which to return the new string pool reference.

Frees the memory used for a string pool created with AllocateStringPool().

Do not free the global string pool (kSPRuntimeStringPool).

Parameters:
stringPool The string pool reference.
SPAPI SPErr(* SPStringsSuite::MakeWString)(SPStringPoolRef stringPool, const char *string, const char **wString)

Adds a string to a string pool, or, if the string has already been added to the pool, retrieves a reference to the pooled string.

Parameters:
stringPool The string pool reference.
string The string.
wString [out] A buffer in which to return the address of the atomized string in the pool.

The documentation for this struct was generated from the following file:


Contents Suites Classes Class Index Member Index
Adobe Solutions Network
 
Copyright © 2016 Adobe Systems Incorporated. All rights reserved.
Terms of Use Online Privacy Policy Adobe and accessibility Avoid software piracy Permissions and Trademarks