Mapping of String

From Apache OpenOffice Wiki
Jump to: navigation, search

A string is a data structure that is common in programming languages. Although the idea of a string is the same, the implementations and their creation can be quite different. For example, a C++ programmer has a range of possibilities to choose from (for example, char*, char[ ], wchar_t*, wchar_t[ ], std::string, CString, BSTR), whereas a JScript programmer can only use one kind of string. To use Automation across languages, it is necessary to use a string type that is common to all those languages, and that has the same binary representation. This particular string is declared as BSTR in COM. The name can be different, depending on the language. For example, in C++ there is a BSTR type, in VB it is called String, and in JScript every string defined is a BSTR. Refer to the documentation covering the BSTRs equivalent if using an Automation capable language not covered by this document.

Content on this page is licensed under the Public Documentation License (PDL).
Personal tools
In other languages