本文整理汇总了C#中XmlQualifiedName.Equals方法的典型用法代码示例。如果您正苦于以下问题:C# XmlQualifiedName.Equals方法的具体用法?C# XmlQualifiedName.Equals怎么用?C# XmlQualifiedName.Equals使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类XmlQualifiedName
的用法示例。
在下文中一共展示了XmlQualifiedName.Equals方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: GetBuiltInComplexType
/// <include file='doc\XmlSchemaType.uex' path='docs/doc[@for="XmlSchemaType.GetXsdComplexType"]/*' />
/// <devdoc>
/// <para>[To be supplied.]</para>
/// </devdoc>
public static XmlSchemaComplexType GetBuiltInComplexType(XmlQualifiedName qualifiedName) {
if (qualifiedName == null) {
throw new ArgumentNullException("qualifiedName");
}
if (qualifiedName.Equals(XmlSchemaComplexType.AnyType.QualifiedName)) {
return XmlSchemaComplexType.AnyType;
}
if (qualifiedName.Equals(XmlSchemaComplexType.UntypedAnyType.QualifiedName)) {
return XmlSchemaComplexType.UntypedAnyType;
}
return null;
}
示例2: MatchEnumeration
private bool MatchEnumeration(XmlQualifiedName value, ArrayList enumeration) {
for (int i = 0; i < enumeration.Count; ++i) {
if (value.Equals((XmlQualifiedName)enumeration[i])) {
return true;
}
}
return false;
}
示例3: MatchEnumeration
private bool MatchEnumeration(XmlQualifiedName value, ArrayList enumeration) {
foreach(XmlQualifiedName correctValue in enumeration) {
if (value.Equals(correctValue)) {
return true;
}
}
return false;
}
示例4: Accepts
private bool Accepts(ContentNode node, XmlQualifiedName qname, int positions, Object index) {
if (index != null) {
BitSet first = node.Firstpos(positions);
for (int i = 0; i < first.Count; i++) {
if (first.Get(i) && qname.Equals(((TerminalNode)terminalNodes[i]).Name))
return true;
}
return false;
}
else {
return node.Accepts(qname);
}
}
示例5: GetAttributeXsd
public SchemaAttDef GetAttributeXsd(SchemaElementDecl ed, XmlQualifiedName qname, XmlSchemaObject partialValidationType, out AttributeMatchState attributeMatchState) {
SchemaAttDef attdef = null;
attributeMatchState = AttributeMatchState.UndeclaredAttribute;
if (ed != null) {
attdef = ed.GetAttDef(qname);
if (attdef != null) {
attributeMatchState = AttributeMatchState.AttributeFound;
return attdef;
}
XmlSchemaAnyAttribute any = ed.AnyAttribute;
if (any != null) {
if (!any.NamespaceList.Allows(qname)) {
attributeMatchState = AttributeMatchState.ProhibitedAnyAttribute;
}
else if (any.ProcessContentsCorrect != XmlSchemaContentProcessing.Skip) {
attdef = (SchemaAttDef)attributeDecls[qname];
if (attdef != null) {
if (attdef.Datatype.TypeCode == XmlTypeCode.Id) { //anyAttribute match whose type is ID
attributeMatchState = AttributeMatchState.AnyIdAttributeFound;
}
else {
attributeMatchState = AttributeMatchState.AttributeFound;
}
}
else if (any.ProcessContentsCorrect == XmlSchemaContentProcessing.Lax) {
attributeMatchState = AttributeMatchState.AnyAttributeLax;
}
}
else {
attributeMatchState = AttributeMatchState.AnyAttributeSkip;
}
}
else if (ed.ProhibitedAttributes[qname] != null) {
attributeMatchState = AttributeMatchState.ProhibitedAttribute;
}
}
else if (partialValidationType != null) {
XmlSchemaAttribute attr = partialValidationType as XmlSchemaAttribute;
if (attr != null) {
if (qname.Equals(attr.QualifiedName)) {
attdef = attr.AttDef;
attributeMatchState = AttributeMatchState.AttributeFound;
}
else {
attributeMatchState = AttributeMatchState.AttributeNameMismatch;
}
}
else {
attributeMatchState = AttributeMatchState.ValidateAttributeInvalidCall;
}
}
else {
attdef = (SchemaAttDef)attributeDecls[qname];
if (attdef != null) {
attributeMatchState = AttributeMatchState.AttributeFound;
}
else {
attributeMatchState = AttributeMatchState.UndeclaredElementAndAttribute;
}
}
return attdef;
}