mirror of
https://github.com/BepInEx/mono.git
synced 2026-11-18 03:51:19 -10:00
* XmlSchema: The Read and Write methods are no more [MonoTODO] :) * XmlSchemaAppInfo: Xml Markup is now being read. * XmlSchemaDocumentation: Xml Markup is now being read. * All: Unhandled attributes are being handled properly. * All: Reordered the properties in all cs files to match with MS Implementation. This was required since the order is importatnt for the XmlSerializer. svn path=/trunk/mcs/; revision=5322
119 lines
2.2 KiB
C#
Executable File
119 lines
2.2 KiB
C#
Executable File
// Author: Dwivedi, Ajay kumar
|
|
// [email protected]
|
|
using System;
|
|
using System.Collections;
|
|
using System.Xml;
|
|
|
|
|
|
namespace System.Xml.Schema
|
|
{
|
|
/// <summary>
|
|
/// Summary description for XmlSchemaCollection.
|
|
/// </summary>
|
|
public sealed class XmlSchemaCollection : ICollection, IEnumerable
|
|
{
|
|
//private fields
|
|
private Hashtable htable;
|
|
private XmlNameTable ntable;
|
|
|
|
[MonoTODO]
|
|
public XmlSchemaCollection()
|
|
{
|
|
htable = new Hashtable();
|
|
ntable = new NameTable();
|
|
}
|
|
public XmlSchemaCollection(XmlNameTable nametable)
|
|
{
|
|
htable = new Hashtable();
|
|
ntable = nametable;
|
|
}
|
|
|
|
//properties
|
|
public int Count
|
|
{
|
|
get
|
|
{
|
|
return this.htable.Count;
|
|
}
|
|
}
|
|
public XmlNameTable NameTable
|
|
{
|
|
get
|
|
{
|
|
return this.ntable;
|
|
}
|
|
}
|
|
public XmlSchema this[ string ns ]
|
|
{
|
|
get
|
|
{
|
|
return (XmlSchema) this.htable[ns];
|
|
}
|
|
}
|
|
|
|
// Events
|
|
public event ValidationEventHandler ValidationEventHandler;
|
|
|
|
// Methods
|
|
[MonoTODO]
|
|
public XmlSchema Add(string ns, XmlReader reader)
|
|
{
|
|
return null;
|
|
}
|
|
[MonoTODO]
|
|
public XmlSchema Add(string ns, string uri)
|
|
{
|
|
return null;
|
|
}
|
|
[MonoTODO]
|
|
public XmlSchema Add(XmlSchema schema)
|
|
{
|
|
return null;
|
|
}
|
|
|
|
public void Add(XmlSchemaCollection schema)
|
|
{
|
|
XmlSchemaCollectionEnumerator xenum = schema.GetEnumerator();
|
|
while(xenum.MoveNext())
|
|
{
|
|
this.Add(xenum.Current);
|
|
}
|
|
}
|
|
|
|
public bool Contains(string ns)
|
|
{
|
|
return this.htable.Contains(ns);
|
|
}
|
|
public bool Contains(XmlSchema schema)
|
|
{
|
|
return this.htable.Contains(schema.TargetNamespace);
|
|
}
|
|
public void CopyTo(XmlSchema[] array, int index)
|
|
{
|
|
|
|
}
|
|
public XmlSchemaCollectionEnumerator GetEnumerator()
|
|
{
|
|
return new XmlSchemaCollectionEnumerator(this.htable);
|
|
}
|
|
|
|
//assembly Methods
|
|
[MonoTODO]
|
|
void ICollection.CopyTo(Array array, int index)
|
|
{
|
|
}
|
|
bool ICollection.IsSynchronized
|
|
{
|
|
get { return false; }
|
|
}
|
|
IEnumerator IEnumerable.GetEnumerator()
|
|
{
|
|
return this.htable.GetEnumerator();
|
|
}
|
|
Object ICollection.SyncRoot
|
|
{
|
|
get { return this; }
|
|
}
|
|
}
|
|
}
|