Show / Hide Table of Contents

Class XmlLanguage

Represents culture information for use in XML and XAML markup.

Inheritance
System.Object
XmlLanguage
Inherited Members
System.Object.Equals(System.Object, System.Object)
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: System.Windows.Markup
Assembly: OpenSilver.dll
Syntax
public sealed class XmlLanguage

Properties

| Improve this Doc View Source

IetfLanguageTag

Gets the string representation of the language tag.

Declaration
public string IetfLanguageTag { get; }
Property Value
Type Description
System.String

Methods

| Improve this Doc View Source

Equals(Object)

Checks for equality of an object to the current object.

Declaration
public override bool Equals(object obj)
Parameters
Type Name Description
System.Object obj

The object to compare to the calling object.

Returns
Type Description
System.Boolean

true if the objects are the same object; otherwise, false.

Overrides
System.Object.Equals(System.Object)
| Improve this Doc View Source

GetHashCode()

Serves as a hash function for the XmlLanguage class.

Declaration
public override int GetHashCode()
Returns
Type Description
System.Int32

An integer hash value.

Overrides
System.Object.GetHashCode()
| Improve this Doc View Source

GetLanguage(String)

Returns a XmlLanguage instance, based on a string representing the language per RFC 3066.

Declaration
public static XmlLanguage GetLanguage(string ietfLanguageTag)
Parameters
Type Name Description
System.String ietfLanguageTag

An RFC 3066 language string, or an empty string ("").

Returns
Type Description
XmlLanguage

A new XmlLanguage with the provided string as its IetfLanguageTag value.

Exceptions
Type Condition
System.ArgumentNullException

ietfLanguageTag is null.

System.ArgumentException

ietfLanguageTag cannot be processed as a valid IETF language.

Operators

| Improve this Doc View Source

Equality(XmlLanguage, XmlLanguage)

Determines whether two specified XmlLanguage objects have the same value.

Declaration
public static bool operator ==(XmlLanguage xmlLanguage1, XmlLanguage xmlLanguage2)
Parameters
Type Name Description
XmlLanguage xmlLanguage1

The first XmlLanguage to compare.

XmlLanguage xmlLanguage2

The second XmlLanguage to compare.

Returns
Type Description
System.Boolean

true if the value of xmlLanguage1 is the same as the value of xmlLanguage2; otherwise, false.

| Improve this Doc View Source

Inequality(XmlLanguage, XmlLanguage)

Determines whether two specified XmlLanguage objects have a different value.

Declaration
public static bool operator !=(XmlLanguage xmlLanguage1, XmlLanguage xmlLanguage2)
Parameters
Type Name Description
XmlLanguage xmlLanguage1

The first XmlLanguage to compare.

XmlLanguage xmlLanguage2

The second XmlLanguage to compare.

Returns
Type Description
System.Boolean

true if the value of xmlLanguage1 is different from the value of xmlLanguage2; otherwise, false.

  • Improve this Doc
  • View Source