public void CheckAttributes(Hashtable presence, bool standalone) {
foreach(SchemaAttDef attdef in attdefs.Values) {
if (presence[attdef.Name] == null) {
if (attdef.Presence == SchemaDeclBase.Use.Required) {
throw new XmlSchemaException(Res.Sch_MissRequiredAttribute, attdef.Name.ToString());
}
else if (standalone && attdef.IsDeclaredInExternal && (attdef.Presence == SchemaDeclBase.Use.Default || attdef.Presence == SchemaDeclBase.Use.Fixed)) {
throw new XmlSchemaException(Res.Sch_StandAlone, string.Empty);
}
}
}
}
};