Imported Upstream version 4.0.0~alpha1

Former-commit-id: 806294f5ded97629b74c85c09952f2a74fe182d9
This commit is contained in:
Jo Shields
2015-04-07 09:35:12 +01:00
parent 283343f570
commit 3c1f479b9d
22469 changed files with 2931443 additions and 869343 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -28,7 +28,6 @@
// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
//
#if NET_2_0
namespace System.Xml.Schema
{
public interface IXmlSchemaInfo
@@ -48,4 +47,3 @@ namespace System.Xml.Schema
XmlSchemaValidity Validity { get; }
}
}
#endif

View File

@@ -28,11 +28,7 @@ namespace System.Xml.Schema
/// <summary>
/// Summary description for ValidationEventArgs.
/// </summary>
#if NET_2_0
public class ValidationEventArgs : EventArgs
#else
public sealed class ValidationEventArgs : EventArgs
#endif
{
private XmlSchemaException exception;
private string message;

View File

@@ -28,7 +28,6 @@
// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
//
#if NET_2_0
using System.Collections;
using System.Xml;
@@ -807,4 +806,3 @@ namespace System.Xml.Schema
}
}
#endif

View File

@@ -476,11 +476,7 @@ namespace System.Xml.Schema
if (this.SourceUri != null && this.SourceUri != String.Empty)
baseUri = new Uri (this.SourceUri);
Uri abs = resolver.ResolveUri (baseUri, relativeUri);
#if NET_2_0
return abs != null ? abs.OriginalString : String.Empty;
#else
return abs != null ? abs.ToString () : String.Empty;
#endif
}
void ProcessExternal (ValidationEventHandler handler, List<CompiledSchemaMemo> handledUris, XmlResolver resolver, XmlSchemaExternal ext, XmlSchemaSet col)

View File

@@ -39,9 +39,7 @@ namespace System.Xml.Schema
public class XmlSchemaAttribute : XmlSchemaAnnotated
{
private object attributeType;
#if NET_2_0
private XmlSchemaSimpleType attributeSchemaType;
#endif
private string defaultValue;
private string fixedValue;
private string validatedDefaultValue;
@@ -158,9 +156,7 @@ namespace System.Xml.Schema
}
[XmlIgnore]
#if NET_2_0
[Obsolete]
#endif
public object AttributeType
{
get{
@@ -171,7 +167,6 @@ namespace System.Xml.Schema
}
}
#if NET_2_0
[XmlIgnore]
public XmlSchemaSimpleType AttributeSchemaType
{
@@ -182,7 +177,6 @@ namespace System.Xml.Schema
return attributeSchemaType;
}
}
#endif
// Post compilation default value (normalized)
internal string ValidatedDefaultValue
@@ -451,7 +445,6 @@ namespace System.Xml.Schema
else
validatedUse = Use;
#if NET_2_0
if (attributeType != null) {
attributeSchemaType = attributeType as XmlSchemaSimpleType;
if (attributeType == XmlSchemaSimpleType.AnySimpleType)
@@ -459,7 +452,6 @@ namespace System.Xml.Schema
if (attributeSchemaType == null)
attributeSchemaType = XmlSchemaType.GetBuiltInSimpleType (SchemaTypeName);
}
#endif
ValidationId = schema.ValidationId;
return errorCount;

View File

@@ -93,11 +93,7 @@ namespace System.Xml.Schema
}
[XmlIgnore]
#if NET_2_0
public XmlQualifiedName QualifiedName
#else
internal XmlQualifiedName QualifiedName
#endif
{
get{ return qualifiedName;}
}

View File

@@ -40,9 +40,7 @@ namespace System.Xml.Schema
/// XmlSchemaCollection is originally designed to be conformant to
/// W3C specification).
/// </summary>
#if NET_2_0
[Obsolete ("Use XmlSchemaSet.")]
#endif
public sealed class XmlSchemaCollection : ICollection, IEnumerable
{
//private fields

View File

@@ -35,11 +35,7 @@ using System.Xml.Serialization;
namespace System.Xml.Schema
{
#if NET_2_0
public
#else
internal
#endif
sealed class XmlSchemaCompilationSettings
{
public XmlSchemaCompilationSettings ()

View File

@@ -620,10 +620,8 @@ namespace System.Xml.Schema
error (h, "Particle whose term is -all- and consists of complex type content particle must have maxOccurs = 1.");
}
#if NET_2_0
if (schema.Schemas.CompilationSettings != null &&
schema.Schemas.CompilationSettings.EnableUpaCheck)
#endif
// This check is optional only after 2.0
contentTypeParticle.ValidateUniqueParticleAttribution (new XmlSchemaObjectTable (),
new ArrayList (), h, schema);

View File

@@ -25,7 +25,6 @@
// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
//
#if NET_2_0
namespace System.Xml.Schema
{
@@ -37,4 +36,3 @@ namespace System.Xml.Schema
}
}
#endif

View File

@@ -43,9 +43,7 @@ namespace System.Xml.Schema
private XmlSchemaObjectCollection constraints;
private string defaultValue;
private object elementType;
#if NET_2_0
private XmlSchemaType elementSchemaType;
#endif
private XmlSchemaDerivationMethod final;
private string fixedValue;
private XmlSchemaForm form;
@@ -216,9 +214,7 @@ namespace System.Xml.Schema
}
[XmlIgnore]
#if NET_2_0
[Obsolete]
#endif
public object ElementType
{
get {
@@ -229,7 +225,6 @@ namespace System.Xml.Schema
}
}
#if NET_2_0
[XmlIgnore]
public XmlSchemaType ElementSchemaType
{
@@ -240,7 +235,6 @@ namespace System.Xml.Schema
return elementSchemaType;
}
}
#endif
[XmlIgnore]
public XmlSchemaDerivationMethod BlockResolved
@@ -745,7 +739,6 @@ namespace System.Xml.Schema
foreach (XmlSchemaIdentityConstraint ident in Constraints)
ident.Validate (h, schema);
#if NET_2_0
if (elementType != null) {
elementSchemaType = elementType as XmlSchemaType;
if (elementType == XmlSchemaSimpleType.AnySimpleType)
@@ -753,7 +746,6 @@ namespace System.Xml.Schema
if (elementSchemaType == null)
elementSchemaType = XmlSchemaType.GetBuiltInSimpleType (SchemaTypeName);
}
#endif
ValidationId = schema.ValidationId;
return errorCount;

View File

@@ -46,18 +46,12 @@ namespace System.Xml.Schema
private XmlSchemaObject sourceObj;
private string sourceUri;
#if NET_2_0
public XmlSchemaException ()
: this ("A schema error occured.", null)
{
}
#endif
#if NET_2_0
public
#else
internal
#endif
XmlSchemaException (string message)
: this (message, null)
{
@@ -73,12 +67,10 @@ namespace System.Xml.Schema
this.sourceObj = info.GetValue ("sourceObj", typeof (XmlSchemaObject)) as XmlSchemaObject;
}
#if NET_2_0
public XmlSchemaException (string message, Exception innerException, int lineNumber, int linePosition)
: this (message, lineNumber, linePosition, null, null, innerException)
{
}
#endif
internal XmlSchemaException (string message, int lineNumber, int linePosition,
XmlSchemaObject sourceObject, string sourceUri, Exception innerException)

View File

@@ -67,11 +67,7 @@ namespace System.Xml.Schema
}
[XmlIgnore]
#if NET_2_0
public XmlQualifiedName QualifiedName
#else
internal XmlQualifiedName QualifiedName
#endif
{
get{ return qualifiedName;}
}

View File

@@ -28,7 +28,6 @@
// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
//
#if NET_2_0
using System;
using System.Collections;
@@ -1162,4 +1161,3 @@ namespace System.Xml.Schema
}
}
#endif

View File

@@ -28,7 +28,6 @@
// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
//
#if NET_2_0
using System;
using System.Runtime.Serialization;
@@ -68,10 +67,8 @@ namespace System.Xml.Schema
{
}
#if NET_2_0
[SecurityPermission (SecurityAction.LinkDemand,
Flags=SecurityPermissionFlag.SerializationFormatter)]
#endif
public override void GetObjectData (
SerializationInfo info, StreamingContext context)
{
@@ -80,4 +77,3 @@ namespace System.Xml.Schema
}
}
#endif

View File

@@ -28,7 +28,6 @@
// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
//
#if NET_2_0
namespace System.Xml.Schema
{
[MonoTODO]
@@ -107,4 +106,3 @@ namespace System.Xml.Schema
}
}
}
#endif

View File

@@ -89,12 +89,8 @@ namespace System.Xml.Schema
set{ sourceUri = value; }
}
#if NET_2_0
[XmlIgnore]
public
#else
internal
#endif
XmlSchemaObject Parent {
get { return parent; }
set { parent = value; }

View File

@@ -29,9 +29,6 @@ namespace System.Xml.Schema
/// <summary>
/// Summary description for XmlSchemaObjectEnumerator.
/// </summary>
#if !NET_2_0
sealed
#endif
public class XmlSchemaObjectEnumerator : IEnumerator
{
private IEnumerator ienum;

View File

@@ -40,11 +40,7 @@ using System.Xml.XPath;
namespace System.Xml.Schema
{
#if NET_2_0
public class XmlSchemaSet
#else
internal sealed class XmlSchemaSet
#endif
{
XmlNameTable nameTable;
XmlResolver xmlResolver = new XmlUrlResolver ();
@@ -121,11 +117,7 @@ namespace System.Xml.Schema
public XmlResolver XmlResolver {
set { xmlResolver = value; }
#if NET_2_0
internal get { return xmlResolver; }
#else
get { return xmlResolver; }
#endif
}
public XmlSchema Add (string targetNamespace, string schemaUri)

Some files were not shown because too many files have changed in this diff Show More