T
The type of value to read.
Noemax FastInfoset.NET Report an issue | Discuss in forums
XmlFastInfosetReader.ReadContentAs<T>(IXmlNamespaceResolver) Method
See Also 
Noemax.FastInfoset Assembly > Noemax.FastInfoset Namespace > XmlFastInfosetReader Class > ReadContentAs Method : Generic ReadContentAs(IXmlNamespaceResolver) Method



namespaceResolver
An IXmlNamespaceResolver object that is used to resolve any namespace prefixes related to type conversion.
Reads the content at the current position as the a value of the type specified.


Namespace: Noemax.FastInfoset
Assembly: Noemax.FastInfoset (in Noemax.FastInfoset.dll)

Syntax

Visual Basic (Declaration) 
Overloads Public Function ReadContentAs(Of T)( _
   ByVal namespaceResolver As IXmlNamespaceResolver _
) As T
Visual Basic (Usage)Copy Code
Dim instance As XmlFastInfosetReader
Dim namespaceResolver As IXmlNamespaceResolver
Dim value As T
 
value = instance.ReadContentAs(Of T)(namespaceResolver)
C# 
public T ReadContentAs<T>( 
   IXmlNamespaceResolver namespaceResolver
)
C++/CLI 
public:
T ReadContentAsgeneric<typename T>
( 
   IXmlNamespaceResolver namespaceResolver
) 

Parameters

namespaceResolver
An IXmlNamespaceResolver object that is used to resolve any namespace prefixes related to type conversion.

Type Parameters

T
The type of value to read.

Return Value

The value of the specified type.

Remarks

This method reads the content at the current reader position and converts it to the requested return type. Only binary content, text, white space, significant white space and CDATA sections are getting processed.

If the content is not encoded as data of T type, the reader will try to perform a type conversion.

See XmlReader.ReadContentAs for more detailed description of the reader behavior.

Version Information

.NET Framework

Supported in: 3.5, 3.0, 2.0

.NET Compact Framework

Supported in: 3.5, 2.0

See Also