Skip to content

Latest commit

 

History

History
154 lines (116 loc) · 5.38 KB

nf-winsync-isyncknowledge2-serializewithoptions.md

File metadata and controls

154 lines (116 loc) · 5.38 KB
UID title description helpviewer_keywords old-location tech.root ms.assetid ms.date ms.keywords req.header req.include-header req.target-type req.target-min-winverclnt req.target-min-winversvr req.kmdf-ver req.umdf-ver req.ddi-compliance req.unicode-ansi req.idl req.max-support req.namespace req.assembly req.type-library req.lib req.dll req.irql targetos req.typenames req.redist ms.custom f1_keywords dev_langs topic_type api_type api_location api_name
NF:winsync.ISyncKnowledge2.SerializeWithOptions
ISyncKnowledge2::SerializeWithOptions (winsync.h)
Serializes the knowledge object data to a byte array based on the specified version and serialization options.
ISyncKnowledge2 interface [Windows Sync]
SerializeWithOptions method
ISyncKnowledge2.SerializeWithOptions
ISyncKnowledge2::SerializeWithOptions
SerializeWithOptions
SerializeWithOptions method [Windows Sync]
SerializeWithOptions method [Windows Sync]
ISyncKnowledge2 interface
winsync.isyncknowledge2_serializewithoptions
winsync/ISyncKnowledge2::SerializeWithOptions
winsync\isyncknowledge2_serializewithoptions.htm
winsync
b8b9084f-f4aa-42b8-8c45-ed075db8ffe4
12/05/2018
ISyncKnowledge2 interface [Windows Sync],SerializeWithOptions method, ISyncKnowledge2.SerializeWithOptions, ISyncKnowledge2::SerializeWithOptions, SerializeWithOptions, SerializeWithOptions method [Windows Sync], SerializeWithOptions method [Windows Sync],ISyncKnowledge2 interface, winsync.isyncknowledge2_serializewithoptions, winsync/ISyncKnowledge2::SerializeWithOptions
winsync.h
Windows
Windows 7 [desktop apps only]
Windows Server 2008 R2 [desktop apps only]
Windows
19H1
ISyncKnowledge2::SerializeWithOptions
winsync/ISyncKnowledge2::SerializeWithOptions
c++
APIRef
kbSyntax
COM
winsync.h
ISyncKnowledge2.SerializeWithOptions

ISyncKnowledge2::SerializeWithOptions

-description

Serializes the knowledge object data to a byte array based on the specified version and serialization options.

-parameters

-param targetFormatVersion [in]

The serialized knowledge is compatible with this version.

-param dwFlags [in]

Options that specify additional information about how to serialize the object. Must be zero or a combination of the values specified by the SYNC_SERIALIZE flags (see Remarks). When zero is specified, the replica key map is not included as part of the serialized knowledge data.

-param pbBuffer [in, out]

The serialized knowledge object data is serialized to this buffer.

-param pdwSerializedSize [in, out]

Specifies the number of bytes in pBuffer. Returns either the number of bytes that are required to serialize the knowledge data when pBuffer is too small, or the number of bytes written.

-returns

The possible return codes include, but are not limited to, the values shown in the following table.

Return code Description
S_OK
The method succeeded.
E_POINTER
Invalid pointer.
HRESULT_FROM_WIN32(ERROR_MORE_DATA)
pBuffer is too small. In this situation, the required number of bytes is returned in pdwSerializedSize.
SYNC_E_INVALID_VERSION
The value of targetFormatVersion is higher than the version of the object, or the object contains elements that are not compatible with targetFormatVersion.

-remarks

Note  The SYNC_SERIALIZE flags are defined as follows:#define SYNC_SERIALIZE_REPLICA_KEY_MAP 0x00000001

The value SYNC_SERIALIZE_REPLICA_KEY_MAP indicates that the replica key map is included in the serialized knowledge data.

When SYNC_SERIALIZE_REPLICA_KEY_MAP is specified for flags, the IReplicaKeyMap object is serialized along with the knowledge data. When this flag is not specified, the IReplicaKeyMap data must be stored in some other way so that the knowledge object can be deserialized.

The value of targetFormatVersion determines the format of the serialized knowledge data and refers to the version of Microsoft Sync Framework. For an overview of what is involved in building synchronization providers using Microsoft Sync Framework, see Options for Building a Synchronization Provider.

-see-also

IReplicaKeyMap Interface

ISyncKnowledge Interface

ISyncKnowledge2 Interface

Options for Building a Synchronization Provider