AtomPubClient class

Applies to Windows and Windows Phone

Encapsulates the methods needed to implement the AtomPub protocol which enables HTTP CRUD access to Web resources using the Atom 1.0 wire format.

Syntax


var atomPubClient = new Windows.Web.AtomPub.AtomPubClient(passwordCredential);
var atomPubClient = new Windows.Web.AtomPub.AtomPubClient();

Attributes

[DualApiPartition()]
[MarshalingBehavior(Agile)]
[Threading(Both)]
[Version(0x06020000)]

Members

The AtomPubClient class has these types of members:

Constructors

The AtomPubClient class has these constructors.

ConstructorDescription
AtomPubClient() Creates a new AtomPubClient object.
AtomPubClient(PasswordCredential) Creates a new AtomPubClient object with the credential to use when making requests to the server. Initially, a 'username/password' tuple. However, for domain credentials, the username must be in 'domain\user form'.

 

Methods

The AtomPubClient class has these methods. With C#, Visual Basic, and C++, it also inherits methods from the Object class.

MethodDescription
CancelAsyncOperations Cancels any in-progress asynchronous operations, causing them to fail (asynchronously) with an error code indicating cancellation.
CreateMediaResourceAsync Creates a new media resource in the specified collection.
CreateResourceAsync Creates a new Entry resource in the specified collection.
DeleteResourceAsync Deletes an existing Entry or Media Link resource.
DeleteResourceItemAsync Deletes an existing Entry or Media Link resource. This differs from the DeleteResourceAsync method in that the SyndicationItem object that represents the resource to be deleted is specified instead of the Uri.
RetrieveFeedAsync Starts an asynchronous operation to download the syndication feed from the given URI. This method instantiates a SyndicationFeed object from the feed string, which can be in one of the formats specified in SyndicationFormat.
RetrieveMediaResourceAsync Retrieves a media link resource from the specified Uniform Resource Identifier (URI).
RetrieveResourceAsync Retrieves an Entry resource or Media Link resource from the specified Uniform Resource Identifier (URI).
RetrieveServiceDocumentAsync Retrieves a service document from the specified Uri.
SetRequestHeader Sets an HTTP header for the request. This method can be called multiple times to set multiple headers. When the same header is set multiple times, the values will be concatenated and separated by ,.
UpdateMediaResourceAsync Updates a media link resource from the specified Uniform Resource Identifier (URI).
UpdateResourceAsync Updates an existing Entry or Media Link resource.
UpdateResourceItemAsync Updates an existing Entry or Media Link resource. This differs from the UpdateResourceAsync method in that the EditUri property of the specified SyndicationItem object is used as the Uri of the resource to be updated.

 

Properties

The AtomPubClient class has these properties.

PropertyAccess typeDescription

BypassCacheOnRetrieve

Read/writeGets or sets a Boolean value that specifies whether to bypass the cache when retrieving the feed.

MaxResponseBufferSize

Read/writeGets or sets the maximum number of bytes to buffer when receiving a response from a server.

ProxyCredential

Read/writeGets or sets the credentials to use when making requests via a proxy.

ServerCredential

Read/writeGets or sets the credentials to use when making requests to the server.

Timeout

Read/writeGets or sets the maximum amount of time, in milliseconds, to wait for any of the asynchronous operations to complete. If the operation is not complete within this amount of time, it will fail with a status code indicating that it timed out.

 

Remarks

For examples of how these class methods are implemented to create, retrieve, update, or delete syndicated content, see Quickstart: Managing Feed Entries.

Requirements

Minimum supported client

Windows 8 [Windows Store apps, desktop apps]

Minimum supported server

Windows Server 2012 [Windows Store apps, desktop apps]

Minimum supported phone

Windows Phone 8.1 [Windows Phone Silverlight 8.1 and Windows Runtime apps]

Namespace

Windows.Web.AtomPub
Windows::Web::AtomPub [C++]

Metadata

Windows.winmd

Capabilities

internetClient
privateNetworkClientServer

See also

Quickstart: Managing Feed Entries
AtomPub sample

 

 

Show:
© 2014 Microsoft. All rights reserved.