ICorProfilerInfo2::GetStringLayout Method

Gets information about the layout of a string object. This method is deprecated in the .NET Framework 4, and is superseded by the ICorProfilerInfo3::GetStringLayout2 method.

Syntax

HRESULT GetStringLayout(  
    [out] ULONG *pBufferLengthOffset,  
    [out] ULONG *pStringLengthOffset,  
    [out] ULONG *pBufferOffset);  

Parameters

pBufferLengthOffset
[out] A pointer to the offset of the location, relative to the ObjectID pointer, that stores the length of the string. The length is stored as a DWORD.

Note

This parameter returns the length of the string itself, not the length of the buffer. The length of the buffer is no longer available.

PStringLengthOffset
[out] A pointer to the offset of the location, relative to the ObjectID pointer, that stores the length of the string itself. The length is stored as a DWORD.

pBufferOffset
[out] A pointer to the offset of the buffer, relative to the ObjectID pointer, that stores the string of wide characters.

Remarks

The GetStringLayout method gets the offsets, relative to the ObjectID pointer, of the locations in which the following are stored:

  • The length of the string's buffer.

  • The length of the string itself.

  • The buffer that contains the actual string of wide characters.

Strings may be null-terminated.

Requirements

Platforms: See System Requirements.

Header: CorProf.idl, CorProf.h

Library: CorGuids.lib

.NET Framework Versions: Available since 2.0

See also