Class SyndicationResourceMetadata
Represents metadata associated with a ISyndicationResource.
Inheritance
Implements
Inherited Members
Namespace: Argotic.Common
Assembly: Argotic.Common.dll
Syntax
[Serializable]
public class SyndicationResourceMetadata : IComparable
Constructors
| Improve this Doc View SourceSyndicationResourceMetadata(XPathNavigator)
Initializes a new instance of the SyndicationResourceMetadata class using the supplied System.Xml.XPath.XPathNavigator.
Declaration
public SyndicationResourceMetadata(XPathNavigator navigator)
Parameters
Type | Name | Description |
---|---|---|
System.Xml.XPath.XPathNavigator | navigator | The System.Xml.XPath.XPathNavigator to extract the syndication resource meta-data from. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | The |
Properties
| Improve this Doc View SourceFormat
Gets the SyndicationContentFormat that the syndication resource conforms to.
Declaration
public SyndicationContentFormat Format { get; protected set; }
Property Value
Type | Description |
---|---|
SyndicationContentFormat | A SyndicationContentFormat enumeration value that indicates the syndication specification the resource conforms to. If the syndication content format is unable to be determined, returns None. |
Namespaces
Gets a dictionary of the XML namespaces declared in the syndication resource.
Declaration
public Dictionary<string, string> Namespaces { get; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.Dictionary<System.String, System.String> | A dictionary of the resource's XML namespaces, keyed off of the namespace prefix. If no XML namespaces are declared on the root element of the resource, returns an empty dictionary. |
Resource
Gets a read-only System.Xml.XPath.XPathNavigator object that can be used to navigate the root element of the syndication resource.
Declaration
public XPathNavigator Resource { get; }
Property Value
Type | Description |
---|---|
System.Xml.XPath.XPathNavigator | A read-only System.Xml.XPath.XPathNavigator object that can be used to navigate the root element of the syndication resource. |
Version
Gets the Version of the syndication specification that the resource conforms to.
Declaration
public Version Version { get; }
Property Value
Type | Description |
---|---|
System.Version | The version number of the syndication specification that the resource conforms to. If format version is unable to be determined, returns null. |
Methods
| Improve this Doc View SourceCompareTo(Object)
Compares the current instance with another object of the same type.
Declaration
public int CompareTo(object obj)
Parameters
Type | Name | Description |
---|---|---|
System.Object | obj | An object to compare with this instance. |
Returns
Type | Description |
---|---|
System.Int32 | A 32-bit signed integer that indicates the relative order of the objects being compared. |
Exceptions
Type | Condition |
---|---|
System.ArgumentException | The |
Equals(Object)
Determines whether the specified System.Object is equal to the current instance.
Declaration
public override bool Equals(object obj)
Parameters
Type | Name | Description |
---|---|---|
System.Object | obj | The System.Object to compare with the current instance. |
Returns
Type | Description |
---|---|
System.Boolean | true if the specified System.Object is equal to the current instance; otherwise, false. |
Overrides
GetHashCode()
Returns a hash code for the current instance.
Declaration
public override int GetHashCode()
Returns
Type | Description |
---|---|
System.Int32 | A 32-bit signed integer hash code. |
Overrides
GetVersionFromAttribute(XPathNavigator, String)
Returns a Version object for the value of the XML attribute in navigator
with a local name specified by name
.
Declaration
protected static Version GetVersionFromAttribute(XPathNavigator navigator, string name)
Parameters
Type | Name | Description |
---|---|---|
System.Xml.XPath.XPathNavigator | navigator | The System.Xml.XPath.XPathNavigator to extract the XML attribute value from. |
System.String | name | The name of the attribute to parse in the |
Returns
Type | Description |
---|---|
System.Version | The Version represented by the value of the specified XML attribute. If unable to determine version, returns null. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | The |
System.ArgumentNullException | The |
System.ArgumentNullException | The |
ToString()
Returns a System.String that represents the current SyndicationResourceMetadata.
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
System.String | A System.String that represents the current SyndicationResourceMetadata. |
Overrides
Remarks
This method returns a human-readable string for the current instance. Hash code values are displayed for applicable properties.
TryParseApmlResource(XPathNavigator, out XPathNavigator, out Version)
Determines if the specified System.Xml.XPath.XPathNavigator represents a Attention Profiling Markup Language (APML) formatted syndication resource.
Declaration
protected static bool TryParseApmlResource(XPathNavigator resource, out XPathNavigator navigator, out Version version)
Parameters
Type | Name | Description |
---|---|---|
System.Xml.XPath.XPathNavigator | resource | A System.Xml.XPath.XPathNavigator that represents the syndication resource to attempt to parse. |
System.Xml.XPath.XPathNavigator | navigator | A System.Xml.XPath.XPathNavigator that can be used to navigate the root element of the syndication resource. This parameter is passed uninitialized. |
System.Version | version | The version of the syndication specification that the resource conforms to. This parameter is passed uninitialized. |
Returns
Type | Description |
---|---|
System.Boolean | true if |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | The |
TryParseAtomPublishingCategoriesResource(XPathNavigator, out XPathNavigator, out Version)
Determines if the specified System.Xml.XPath.XPathNavigator represents a Atom Publishing Protocol category document formatted syndication resource.
Declaration
protected static bool TryParseAtomPublishingCategoriesResource(XPathNavigator resource, out XPathNavigator navigator, out Version version)
Parameters
Type | Name | Description |
---|---|---|
System.Xml.XPath.XPathNavigator | resource | A System.Xml.XPath.XPathNavigator that represents the syndication resource to attempt to parse. |
System.Xml.XPath.XPathNavigator | navigator | A System.Xml.XPath.XPathNavigator that can be used to navigate the root element of the syndication resource. This parameter is passed uninitialized. |
System.Version | version | The version of the syndication specification that the resource conforms to. This parameter is passed uninitialized. |
Returns
Type | Description |
---|---|
System.Boolean | true if |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | The |
TryParseAtomPublishingServiceResource(XPathNavigator, out XPathNavigator, out Version)
Determines if the specified System.Xml.XPath.XPathNavigator represents a Atom Publishing Protocol service document formatted syndication resource.
Declaration
protected static bool TryParseAtomPublishingServiceResource(XPathNavigator resource, out XPathNavigator navigator, out Version version)
Parameters
Type | Name | Description |
---|---|---|
System.Xml.XPath.XPathNavigator | resource | A System.Xml.XPath.XPathNavigator that represents the syndication resource to attempt to parse. |
System.Xml.XPath.XPathNavigator | navigator | A System.Xml.XPath.XPathNavigator that can be used to navigate the root element of the syndication resource. This parameter is passed uninitialized. |
System.Version | version | The version of the syndication specification that the resource conforms to. This parameter is passed uninitialized. |
Returns
Type | Description |
---|---|
System.Boolean | true if |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | The |
TryParseAtomResource(XPathNavigator, out XPathNavigator, out Version)
Determines if the specified System.Xml.XPath.XPathNavigator represents a Atom formatted syndication resource.
Declaration
protected static bool TryParseAtomResource(XPathNavigator resource, out XPathNavigator navigator, out Version version)
Parameters
Type | Name | Description |
---|---|---|
System.Xml.XPath.XPathNavigator | resource | A System.Xml.XPath.XPathNavigator that represents the syndication resource to attempt to parse. |
System.Xml.XPath.XPathNavigator | navigator | A System.Xml.XPath.XPathNavigator that can be used to navigate the root element of the syndication resource. This parameter is passed uninitialized. |
System.Version | version | The version of the syndication specification that the resource conforms to. This parameter is passed uninitialized. |
Returns
Type | Description |
---|---|
System.Boolean | true if |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | The |
TryParseBlogMLResource(XPathNavigator, out XPathNavigator, out Version)
Determines if the specified System.Xml.XPath.XPathNavigator represents a Web Log Markup Language (BlogML) formatted syndication resource.
Declaration
protected static bool TryParseBlogMLResource(XPathNavigator resource, out XPathNavigator navigator, out Version version)
Parameters
Type | Name | Description |
---|---|---|
System.Xml.XPath.XPathNavigator | resource | A System.Xml.XPath.XPathNavigator that represents the syndication resource to attempt to parse. |
System.Xml.XPath.XPathNavigator | navigator | A System.Xml.XPath.XPathNavigator that can be used to navigate the root element of the syndication resource. This parameter is passed uninitialized. |
System.Version | version | The version of the syndication specification that the resource conforms to. This parameter is passed uninitialized. |
Returns
Type | Description |
---|---|
System.Boolean | true if |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | The |
TryParseMicroSummaryGeneratorResource(XPathNavigator, out XPathNavigator, out Version)
Determines if the specified System.Xml.XPath.XPathNavigator represents a Microsummary Generator formatted syndication resource.
Declaration
protected static bool TryParseMicroSummaryGeneratorResource(XPathNavigator resource, out XPathNavigator navigator, out Version version)
Parameters
Type | Name | Description |
---|---|---|
System.Xml.XPath.XPathNavigator | resource | A System.Xml.XPath.XPathNavigator that represents the syndication resource to attempt to parse. |
System.Xml.XPath.XPathNavigator | navigator | A System.Xml.XPath.XPathNavigator that can be used to navigate the root element of the syndication resource. This parameter is passed uninitialized. |
System.Version | version | The version of the syndication specification that the resource conforms to. This parameter is passed uninitialized. |
Returns
Type | Description |
---|---|
System.Boolean | true if |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | The |
TryParseNewsMLResource(XPathNavigator, out XPathNavigator, out Version)
Determines if the specified System.Xml.XPath.XPathNavigator represents a News Markup Language (NewsML) formatted syndication resource.
Declaration
protected static bool TryParseNewsMLResource(XPathNavigator resource, out XPathNavigator navigator, out Version version)
Parameters
Type | Name | Description |
---|---|---|
System.Xml.XPath.XPathNavigator | resource | A System.Xml.XPath.XPathNavigator that represents the syndication resource to attempt to parse. |
System.Xml.XPath.XPathNavigator | navigator | A System.Xml.XPath.XPathNavigator that can be used to navigate the root element of the syndication resource. This parameter is passed uninitialized. |
System.Version | version | The version of the syndication specification that the resource conforms to. This parameter is passed uninitialized. |
Returns
Type | Description |
---|---|
System.Boolean | true if |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | The |
TryParseOpenSearchDescriptionResource(XPathNavigator, out XPathNavigator, out Version)
Determines if the specified System.Xml.XPath.XPathNavigator represents a OpenSearch Description formatted syndication resource.
Declaration
protected static bool TryParseOpenSearchDescriptionResource(XPathNavigator resource, out XPathNavigator navigator, out Version version)
Parameters
Type | Name | Description |
---|---|---|
System.Xml.XPath.XPathNavigator | resource | A System.Xml.XPath.XPathNavigator that represents the syndication resource to attempt to parse. |
System.Xml.XPath.XPathNavigator | navigator | A System.Xml.XPath.XPathNavigator that can be used to navigate the root element of the syndication resource. This parameter is passed uninitialized. |
System.Version | version | The version of the syndication specification that the resource conforms to. This parameter is passed uninitialized. |
Returns
Type | Description |
---|---|
System.Boolean | true if |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | The |
TryParseOpmlResource(XPathNavigator, out XPathNavigator, out Version)
Determines if the specified System.Xml.XPath.XPathNavigator represents a Outline Processor Markup Language (OPML) formatted syndication resource.
Declaration
protected static bool TryParseOpmlResource(XPathNavigator resource, out XPathNavigator navigator, out Version version)
Parameters
Type | Name | Description |
---|---|---|
System.Xml.XPath.XPathNavigator | resource | A System.Xml.XPath.XPathNavigator that represents the syndication resource to attempt to parse. |
System.Xml.XPath.XPathNavigator | navigator | A System.Xml.XPath.XPathNavigator that can be used to navigate the root element of the syndication resource. This parameter is passed uninitialized. |
System.Version | version | The version of the syndication specification that the resource conforms to. This parameter is passed uninitialized. |
Returns
Type | Description |
---|---|
System.Boolean | true if |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | The |
TryParseRsdResource(XPathNavigator, out XPathNavigator, out Version)
Determines if the specified System.Xml.XPath.XPathNavigator represents a Really Simple Discovery (RSD) formatted syndication resource.
Declaration
protected static bool TryParseRsdResource(XPathNavigator resource, out XPathNavigator navigator, out Version version)
Parameters
Type | Name | Description |
---|---|---|
System.Xml.XPath.XPathNavigator | resource | A System.Xml.XPath.XPathNavigator that represents the syndication resource to attempt to parse. |
System.Xml.XPath.XPathNavigator | navigator | A System.Xml.XPath.XPathNavigator that can be used to navigate the root element of the syndication resource. This parameter is passed uninitialized. |
System.Version | version | The version of the syndication specification that the resource conforms to. This parameter is passed uninitialized. |
Returns
Type | Description |
---|---|
System.Boolean | true if |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | The |
TryParseRssResource(XPathNavigator, out XPathNavigator, out Version)
Determines if the specified System.Xml.XPath.XPathNavigator represents a Really Simple Syndication (RSS) formatted syndication resource.
Declaration
protected static bool TryParseRssResource(XPathNavigator resource, out XPathNavigator navigator, out Version version)
Parameters
Type | Name | Description |
---|---|---|
System.Xml.XPath.XPathNavigator | resource | A System.Xml.XPath.XPathNavigator that represents the syndication resource to attempt to parse. |
System.Xml.XPath.XPathNavigator | navigator | A System.Xml.XPath.XPathNavigator that can be used to navigate the root element of the syndication resource. This parameter is passed uninitialized. |
System.Version | version | The version of the syndication specification that the resource conforms to. This parameter is passed uninitialized. |
Returns
Type | Description |
---|---|
System.Boolean | true if |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | The |
Operators
| Improve this Doc View SourceEquality(SyndicationResourceMetadata, SyndicationResourceMetadata)
Determines if operands are equal.
Declaration
public static bool operator ==(SyndicationResourceMetadata first, SyndicationResourceMetadata second)
Parameters
Type | Name | Description |
---|---|---|
SyndicationResourceMetadata | first | Operand to be compared. |
SyndicationResourceMetadata | second | Operand to compare to. |
Returns
Type | Description |
---|---|
System.Boolean | true if the values of its operands are equal, otherwise; false. |
GreaterThan(SyndicationResourceMetadata, SyndicationResourceMetadata)
Determines if first operand is greater than second operand.
Declaration
public static bool operator>(SyndicationResourceMetadata first, SyndicationResourceMetadata second)
Parameters
Type | Name | Description |
---|---|---|
SyndicationResourceMetadata | first | Operand to be compared. |
SyndicationResourceMetadata | second | Operand to compare to. |
Returns
Type | Description |
---|---|
System.Boolean | true if the first operand is greater than the second, otherwise; false. |
Inequality(SyndicationResourceMetadata, SyndicationResourceMetadata)
Determines if operands are not equal.
Declaration
public static bool operator !=(SyndicationResourceMetadata first, SyndicationResourceMetadata second)
Parameters
Type | Name | Description |
---|---|---|
SyndicationResourceMetadata | first | Operand to be compared. |
SyndicationResourceMetadata | second | Operand to compare to. |
Returns
Type | Description |
---|---|
System.Boolean | false if its operands are equal, otherwise; true. |
LessThan(SyndicationResourceMetadata, SyndicationResourceMetadata)
Determines if first operand is less than second operand.
Declaration
public static bool operator <(SyndicationResourceMetadata first, SyndicationResourceMetadata second)
Parameters
Type | Name | Description |
---|---|---|
SyndicationResourceMetadata | first | Operand to be compared. |
SyndicationResourceMetadata | second | Operand to compare to. |
Returns
Type | Description |
---|---|
System.Boolean | true if the first operand is less than the second, otherwise; false. |