WS_XML_WRITER_RAW_ENCODING structure (webservices.h)

Used to indicate that the writer should emit bytes from decoded base64 characters.

Syntax

typedef struct _WS_XML_WRITER_RAW_ENCODING {
  WS_XML_WRITER_ENCODING encoding;
} WS_XML_WRITER_RAW_ENCODING;

Members

encoding

The base type for all types that derive from WS_XML_WRITER_ENCODING.

Remarks

This encoding can be useful when it is desirable to write an arbitrary, perhaps, non-xml document while still using the WS_XML_WRITER abstraction. In this encoding, only characters representing base64 encoded bytes may be written, and only at the root of the document. No elements or comments may be written. The writer will emit the bytes represented by the base64 encoded characters. In order to accommodate non-whitespace text at the root of the document, the writer will operate as if the WS_XML_WRITER_PROPERTY_ALLOW_FRAGMENT property has been specified.

The base64 characters of the document are only converted to bytes when necessary. So, for example, using WsWriteBytes, which normally performs a base64 encoding of the bytes it is passed, actually avoids all base64 conversions and is the most efficient way to write documents in this encoding. Using WsWriteChars, for example, will cause the base64 characters to physically get decoded to their corresponding bytes. In general writing the document using anything other than WsReadBytes, WsPullBytes, or WsPushBytes will incur the base64 conversion.

Requirements

Requirement Value
Minimum supported client Windows 7 [desktop apps only]
Minimum supported server Windows Server 2008 R2 [desktop apps only]
Header webservices.h