当前位置: 首页>>代码示例>>C#>>正文


C# XmlQualifiedName.Equals方法代码示例

本文整理汇总了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;
 }
开发者ID:uQr,项目名称:referencesource,代码行数:16,代码来源:XmlSchemaType.cs

示例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;
 }
开发者ID:uQr,项目名称:referencesource,代码行数:8,代码来源:FacetChecker.cs

示例3: MatchEnumeration

 private bool MatchEnumeration(XmlQualifiedName value, ArrayList enumeration) {
     foreach(XmlQualifiedName correctValue in enumeration) {
         if (value.Equals(correctValue)) {
             return true;
         }
     }
     return false;
 }
开发者ID:gbarnett,项目名称:shared-source-cli-2.0,代码行数:8,代码来源:facetchecker.cs

示例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);
     }
 }
开发者ID:ArildF,项目名称:masters,代码行数:13,代码来源:compiledcontentmodel.cs

示例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;
 }
开发者ID:gbarnett,项目名称:shared-source-cli-2.0,代码行数:62,代码来源:schemainfo.cs


注:本文中的XmlQualifiedName.Equals方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。