XmlDictionary.TryLookup Method
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Attempts to look up an entry in the dictionary.
TryLookup(Int32, XmlDictionaryString) |
Attempts to look up an entry in the dictionary. |
TryLookup(String, XmlDictionaryString) |
Checks the dictionary for a specified string value. |
TryLookup(XmlDictionaryString, XmlDictionaryString) |
Checks the dictionary for a specified XmlDictionaryString. |
This method avoids throwing an exception if the string is not currently in the dictionary.
- Source:
- XmlDictionary.cs
- Source:
- XmlDictionary.cs
- Source:
- XmlDictionary.cs
Attempts to look up an entry in the dictionary.
public:
virtual bool TryLookup(int key, [Runtime::InteropServices::Out] System::Xml::XmlDictionaryString ^ % result);
public virtual bool TryLookup(int key, out System.Xml.XmlDictionaryString result);
public virtual bool TryLookup(int key, out System.Xml.XmlDictionaryString? result);
abstract member TryLookup : int * XmlDictionaryString -> bool
override this.TryLookup : int * XmlDictionaryString -> bool
Public Overridable Function TryLookup (key As Integer, ByRef result As XmlDictionaryString) As Boolean
Parameters
- key
- Int32
Key to look up.
- result
- XmlDictionaryString
If key
is defined, the XmlDictionaryString that is mapped to the key; otherwise null
.
Returns
true
if key is in the dictionary; otherwise, false
.
Implements
Applies to
.NET 10 and other versions
Product | Versions |
---|---|
.NET | Core 1.0, Core 1.1, Core 2.0, Core 2.1, Core 2.2, Core 3.0, Core 3.1, 5, 6, 7, 8, 9, 10 |
.NET Framework | 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |
.NET Standard | 2.0, 2.1 |
UWP | 10.0 |
- Source:
- XmlDictionary.cs
- Source:
- XmlDictionary.cs
- Source:
- XmlDictionary.cs
Checks the dictionary for a specified string value.
public:
virtual bool TryLookup(System::String ^ value, [Runtime::InteropServices::Out] System::Xml::XmlDictionaryString ^ % result);
public virtual bool TryLookup(string value, out System.Xml.XmlDictionaryString result);
public virtual bool TryLookup(string value, out System.Xml.XmlDictionaryString? result);
abstract member TryLookup : string * XmlDictionaryString -> bool
override this.TryLookup : string * XmlDictionaryString -> bool
Public Overridable Function TryLookup (value As String, ByRef result As XmlDictionaryString) As Boolean
Parameters
- value
- String
String value being checked for.
- result
- XmlDictionaryString
The corresponding XmlDictionaryString, if found; otherwise null
.
Returns
true
if value is in the dictionary; otherwise, false
.
Implements
Exceptions
value
is null
.
Applies to
.NET 10 and other versions
Product | Versions |
---|---|
.NET | Core 1.0, Core 1.1, Core 2.0, Core 2.1, Core 2.2, Core 3.0, Core 3.1, 5, 6, 7, 8, 9, 10 |
.NET Framework | 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |
.NET Standard | 2.0, 2.1 |
UWP | 10.0 |
- Source:
- XmlDictionary.cs
- Source:
- XmlDictionary.cs
- Source:
- XmlDictionary.cs
Checks the dictionary for a specified XmlDictionaryString.
public:
virtual bool TryLookup(System::Xml::XmlDictionaryString ^ value, [Runtime::InteropServices::Out] System::Xml::XmlDictionaryString ^ % result);
public virtual bool TryLookup(System.Xml.XmlDictionaryString value, out System.Xml.XmlDictionaryString result);
public virtual bool TryLookup(System.Xml.XmlDictionaryString value, out System.Xml.XmlDictionaryString? result);
abstract member TryLookup : System.Xml.XmlDictionaryString * XmlDictionaryString -> bool
override this.TryLookup : System.Xml.XmlDictionaryString * XmlDictionaryString -> bool
Public Overridable Function TryLookup (value As XmlDictionaryString, ByRef result As XmlDictionaryString) As Boolean
Parameters
- value
- XmlDictionaryString
The XmlDictionaryString being checked for.
- result
- XmlDictionaryString
The matching XmlDictionaryString, if found; otherwise, null
.
Returns
true
if XmlDictionaryString is in the dictionary; otherwise, false
.
Implements
Exceptions
value
is null
.
Applies to
.NET 10 and other versions
Product | Versions |
---|---|
.NET | Core 1.0, Core 1.1, Core 2.0, Core 2.1, Core 2.2, Core 3.0, Core 3.1, 5, 6, 7, 8, 9, 10 |
.NET Framework | 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |
.NET Standard | 2.0, 2.1 |
UWP | 10.0 |
.NET feedback
.NET is an open source project. Select a link to provide feedback: