SyndicationCategory Class

 

A class that represents the category of a syndication feed.

Namespace:   System.ServiceModel.Syndication
Assembly:  System.ServiceModel (in System.ServiceModel.dll)

System.Object
  System.ServiceModel.Syndication.SyndicationCategory

Public Class SyndicationCategory

NameDescription
System_CAPS_pubmethodSyndicationCategory()

Initializes a new instance of the SyndicationCategory class.

System_CAPS_pubmethodSyndicationCategory(String)

Initializes a new instance of the SyndicationCategory class with the given name.

System_CAPS_pubmethodSyndicationCategory(String, String, String)

Initializes a new instance of the SyndicationCategory class with the specified name, scheme, and label.

System_CAPS_protmethodSyndicationCategory(SyndicationCategory)

Initializes a new instance of the SyndicationCategory class with the specified SyndicationCategory instance.

NameDescription
System_CAPS_pubpropertyAttributeExtensions

Gets the attribute extensions for this category.

System_CAPS_pubpropertyElementExtensions

Gets the element extensions for this category.

System_CAPS_pubpropertyLabel

Gets and sets the label of the category.

System_CAPS_pubpropertyName

Gets and sets the name of the category.

System_CAPS_pubpropertyScheme

Gets and sets the scheme of the category.

NameDescription
System_CAPS_pubmethodClone()

Creates a copy of a SyndicationCategory instance.

System_CAPS_pubmethodEquals(Object)

Determines whether the specified object is equal to the current object.(Inherited from Object.)

System_CAPS_protmethodFinalize()

Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.(Inherited from Object.)

System_CAPS_pubmethodGetHashCode()

Serves as the default hash function. (Inherited from Object.)

System_CAPS_pubmethodGetType()

Gets the Type of the current instance.(Inherited from Object.)

System_CAPS_protmethodMemberwiseClone()

Creates a shallow copy of the current Object.(Inherited from Object.)

System_CAPS_pubmethodToString()

Returns a string that represents the current object.(Inherited from Object.)

System_CAPS_protmethodTryParseAttribute(String, String, String, String)

Attempts to parse an attribute extension.

System_CAPS_protmethodTryParseElement(XmlReader, String)

Attempts to parse an element extension.

System_CAPS_protmethodWriteAttributeExtensions(XmlWriter, String)

Writes the attribute extensions to the specified writer.

System_CAPS_protmethodWriteElementExtensions(XmlWriter, String)

Writes the element extensions to the specified writer.

A category allows you to assign one or more keywords that can be used to search for information.

The following code shows how to create a SyndicationFeed and add a SyndicationItem with a SyndicationCategory.

Imports System
Imports System.ServiceModel.Syndication
Imports System.Collections.Generic
imports System.Collections.ObjectModel


Module Program

    Sub Main()
        Dim myFeed As New SyndicationFeed("My Test Feed", _
                                                     "This is a test feed", _
                                                     New Uri("http://FeedServer/Test"), "MyFeedId", DateTime.Now)
        Dim myItem As New SyndicationItem("Item One Title", _
                                                     "Item One Content", _
                                                     New Uri("http://FeedServer/Test/ItemOne"))
        myItem.Categories.Add(New SyndicationCategory("MyCategory"))
        Dim items As New Collection(Of SyndicationItem)()
        items.Add(myItem)
        myFeed.Items = items
    End Sub

End Module

.NET Framework
Available since 3.5
Silverlight
Available since 2.0

Any public static ( Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Return to top
Show: