Skip to content

Commit

Permalink
Change nullability of public IXmlNamespaceResolver parameters where a…
Browse files Browse the repository at this point in the history
…ppropriate (#41079)
  • Loading branch information
jozkee authored Aug 20, 2020
1 parent ff44e33 commit 0a0eeae
Show file tree
Hide file tree
Showing 9 changed files with 11 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1784,7 +1784,7 @@ public override object ReadContentAsObject()
return base.ReadContentAsObject();
}

public override object ReadContentAs(Type returnType, IXmlNamespaceResolver namespaceResolver)
public override object ReadContentAs(Type returnType, IXmlNamespaceResolver? namespaceResolver)
{
int origPos = _pos;
try
Expand Down Expand Up @@ -4229,7 +4229,7 @@ private XmlValueConverter GetValueConverter(XmlTypeCode typeCode)
return xsst.ValueConverter;
}

private object ValueAs(BinXmlToken token, Type returnType, IXmlNamespaceResolver namespaceResolver)
private object ValueAs(BinXmlToken token, Type returnType, IXmlNamespaceResolver? namespaceResolver)
{
object value;
CheckValueTokenBounds();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -278,7 +278,7 @@ public override string ReadContentAsString()
return _coreReader.ReadContentAsString();
}

public override object ReadContentAs(Type returnType, IXmlNamespaceResolver namespaceResolver)
public override object ReadContentAs(Type returnType, IXmlNamespaceResolver? namespaceResolver)
{
CheckAsync();
return _coreReader.ReadContentAs(returnType, namespaceResolver);
Expand Down Expand Up @@ -801,7 +801,7 @@ public override Task<string> ReadContentAsStringAsync()
return task;
}

public override Task<object> ReadContentAsAsync(Type returnType, IXmlNamespaceResolver namespaceResolver)
public override Task<object> ReadContentAsAsync(Type returnType, IXmlNamespaceResolver? namespaceResolver)
{
CheckAsync();
var task = _coreReader.ReadContentAsAsync(returnType, namespaceResolver);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -378,7 +378,7 @@ public virtual string ReadContentAsString()

// Concatenates values of textual nodes of the current content, ignoring comments and PIs, expanding entity references,
// and converts the content to the requested type. Stops at start tags and end tags.
public virtual object ReadContentAs(Type returnType, IXmlNamespaceResolver namespaceResolver)
public virtual object ReadContentAs(Type returnType, IXmlNamespaceResolver? namespaceResolver)
{
if (!CanReadContentAs())
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public virtual Task<string> ReadContentAsStringAsync()

// Concatenates values of textual nodes of the current content, ignoring comments and PIs, expanding entity references,
// and converts the content to the requested type. Stops at start tags and end tags.
public virtual async Task<object> ReadContentAsAsync(Type returnType, IXmlNamespaceResolver namespaceResolver)
public virtual async Task<object> ReadContentAsAsync(Type returnType, IXmlNamespaceResolver? namespaceResolver)
{
if (!CanReadContentAs())
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -799,7 +799,7 @@ public override string ReadContentAsString()
}
}

public override object ReadContentAs(Type returnType, IXmlNamespaceResolver namespaceResolver)
public override object ReadContentAs(Type returnType, IXmlNamespaceResolver? namespaceResolver)
{
try
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ public override async Task<string> ReadContentAsStringAsync()
}
}

public override async Task<object> ReadContentAsAsync(Type returnType, IXmlNamespaceResolver namespaceResolver)
public override async Task<object> ReadContentAsAsync(Type returnType, IXmlNamespaceResolver? namespaceResolver)
{
try
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -728,7 +728,7 @@ public override string ReadContentAsString()
}
}

public override object ReadContentAs(Type returnType, IXmlNamespaceResolver namespaceResolver)
public override object ReadContentAs(Type returnType, IXmlNamespaceResolver? namespaceResolver)
{
if (!CanReadContentAs(this.NodeType))
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ public override async Task<string> ReadContentAsStringAsync()
}
}

public override async Task<object> ReadContentAsAsync(Type returnType, IXmlNamespaceResolver namespaceResolver)
public override async Task<object> ReadContentAsAsync(Type returnType, IXmlNamespaceResolver? namespaceResolver)
{
if (!CanReadContentAs(this.NodeType))
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ internal XPathExpression() { }

public abstract void SetContext(XmlNamespaceManager nsManager);

public abstract void SetContext(IXmlNamespaceResolver nsResolver);
public abstract void SetContext(IXmlNamespaceResolver? nsResolver);

public abstract XPathResultType ReturnType { get; }

Expand Down

0 comments on commit 0a0eeae

Please sign in to comment.