WsResetMetadata function (webservices.h)

Resets a metadata object state to WS_METADATA_STATE_CREATED.

In this state the Metadata object can be reused. WS_POLICY objects that were retrieved using the Metadata object will be released.

Syntax

HRESULT WsResetMetadata(
  [in]           WS_METADATA *metadata,
  [in, optional] WS_ERROR    *error
);

Parameters

[in] metadata

A pointer to the Metadata object to reset. The pointer must reference a valid WS_METADATA.

[in, optional] error

A pointer to a WS_ERROR object where additional information about the error should be stored if the function fails.

Return value

This function can return one of these values.

Return code Description
WS_E_INVALID_OPERATION
The metadata was in an inappropriate state.

Remarks

Reusing a metadata instead of creating one from scratch may improve performance. If called correctly, this function will not fail.

Requirements

Requirement Value
Minimum supported client Windows 7 [desktop apps | UWP apps]
Minimum supported server Windows Server 2008 R2 [desktop apps | UWP apps]
Target Platform Windows
Header webservices.h
Library WebServices.lib
DLL WebServices.dll