void AddSchemaImport(string ns, string referencingNs) {
if (referencingNs == null || ns == null) return;
if (ns == referencingNs) return;
XmlSchema schema = schemas[referencingNs];
if (schema == null) throw new InvalidOperationException(Res.GetString(Res.XmlMissingSchema, referencingNs));
if (ns != null && ns.Length > 0 && FindImport(schema, ns) == null) {
XmlSchemaImport import = new XmlSchemaImport();
import.Namespace = ns;
schema.Includes.Add(import);
}
}