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


C# IHTMLItem.IsValid方法代码示例

本文整理汇总了C#中IHTMLItem.IsValid方法的典型用法代码示例。如果您正苦于以下问题:C# IHTMLItem.IsValid方法的具体用法?C# IHTMLItem.IsValid怎么用?C# IHTMLItem.IsValid使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在IHTMLItem的用法示例。


在下文中一共展示了IHTMLItem.IsValid方法的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: IsValidSubType

 protected override bool IsValidSubType(IHTMLItem item)
 {
     if (item is IInlineItem)
     {
         return item.IsValid();
     }
     if (item is SimpleHTML5Text)
     {
         return item.IsValid();
     }
     return false;
 }
开发者ID:rajeshwarn,项目名称:fb2converters,代码行数:12,代码来源:TableCaption.cs

示例2: IsValidSubType

 protected override bool IsValidSubType(IHTMLItem item)
 {
     if (item is DefinitionDescription)
     {
         return item.IsValid();
     }
     if (item is DefinitionTerms)
     {
         return item.IsValid();
     }
     return false;
 }
开发者ID:npuBug,项目名称:fb2epub,代码行数:12,代码来源:DefinitionList.cs

示例3: IsValidSubType

 protected override bool IsValidSubType(IHTMLItem item)
 {
     if (item is Area)
     {
         return item.IsValid();
     }
     if (item is IBlockElement)
     {
         return item.IsValid();
     }
     return false;
 }
开发者ID:rajeshwarn,项目名称:fb2converters,代码行数:12,代码来源:Map.cs

示例4: IsValidSubType

 protected override bool IsValidSubType(IHTMLItem item)
 {
     if (item is Option)
     {
         return item.IsValid();
     }
     return false;
 }
开发者ID:npuBug,项目名称:fb2epub,代码行数:8,代码来源:OptionGroup.cs

示例5: IsValidSubType

 protected override bool IsValidSubType(IHTMLItem item)
 {
     if (item is IInlineItem)
     {
         // TODO: check for label presence at depth
         if (item is Label)
         {
             return false;
         }
         return item.IsValid();
     }
     if (item is SimpleHTML5Text)
     {
         return item.IsValid();
     }
     return false;
 }
开发者ID:npuBug,项目名称:fb2epub,代码行数:17,代码来源:Label.cs

示例6: IsValidSubType

 protected override bool IsValidSubType(IHTMLItem item)
 {
     // TODO: full check for ruby sequence
     if (item is IRubyItem)
     {
         return item.IsValid();
     }
     return false;
 }
开发者ID:npuBug,项目名称:fb2epub,代码行数:9,代码来源:RubyElement.cs

示例7: IsValidSubType

 protected override bool IsValidSubType(IHTMLItem item)
 {
     if (item is Title   ||
         item is Base    ||
         item is Link    ||
         item is Meta    ||
         item is Script  ||
         item is Style   ||
         item is NoScript
         )
     {
         return item.IsValid();
     }
     return false;
 }
开发者ID:npuBug,项目名称:fb2epub,代码行数:15,代码来源:Head.cs

示例8: IsValidSubType

 protected override bool IsValidSubType(IHTMLItem item)
 {
     if (item is Header)
     {
         return false;
     }
     if (item is Footer)
     {
         return false;
     }
     if (item is IInlineItem ||
         item is IBlockElement ||
         item is SimpleHTML5Text)
     {
         return item.IsValid();
     }
     return false;
 }
开发者ID:rajeshwarn,项目名称:fb2converters,代码行数:18,代码来源:Header.cs

示例9: IsValidSubType

        protected override bool IsValidSubType(IHTMLItem item)
        {
            if (Subitems.Count >= 2) // no more than two sub elements
            {
                return false;
            }
            if (Subitems.Count == 0) // head have to be first
            {
                if (!(item is Head)  )
                {
                    return false;
                }
            }
            if (Subitems.Count == 1) // body have to be second
            {
                if (!(item is Body)  )
                {
                    return false;
                }
            }

            return item.IsValid();
        }
开发者ID:npuBug,项目名称:fb2epub,代码行数:23,代码来源:HTML.cs

示例10: IsValidSubType

 protected override bool IsValidSubType(IHTMLItem item)
 {
     if (item is TableData)
     {
         return item.IsValid();
     }
     if (item is TableHeaderCell)
     {
         return item.IsValid();
     }
     return false;
 }
开发者ID:rajeshwarn,项目名称:fb2converters,代码行数:12,代码来源:TableRow.cs

示例11: IsValidSubType

 protected override bool IsValidSubType(IHTMLItem item)
 {
     if (
         !(item is Input) &&
         !(item is TextArea) &&
         !(item is Button) &&
         !(item is Select) &&
         !(item is Option) &&
         !(item is OptionGroup) &&
         !(item is Label) &&
         !(item is FieldSet))
     {
         return false;
     }
     return item.IsValid();
 }
开发者ID:rajeshwarn,项目名称:fb2converters,代码行数:16,代码来源:Form.cs

示例12: IsValidSubType

 protected override bool IsValidSubType(IHTMLItem item)
 {
     // may appear only once and only as first element
     if (item is TableCaption)
     {
         if (Subitems.Count > 0)
         {
             return false;
         }
         IHTMLItem seekItem = Subitems.Find(x => x is TableCaption);
         if (seekItem != null)
         {
             return false;
         }
         return item.IsValid();
     }
     if (item is ColElement)
     {
         return item.IsValid();
     }
     if (item is ColGroup)
     {
         return item.IsValid();
     }
     if (item is TableBody)
     {
         IHTMLItem seekItem = Subitems.Find(x => x is TableBody);
         if (seekItem != null)
         {
             return false;
         }
         seekItem = Subitems.Find(x => x is TableRow);
         if (seekItem != null)
         {
             return false;
         }
         return item.IsValid();
     }
     if (item is TableRow)
     {
         IHTMLItem seekItem = Subitems.Find(x => x is TableBody);
         if (seekItem != null)
         {
             return false;
         }
         seekItem = Subitems.Find(x => x is TableHead);
         if (seekItem != null)
         {
             return false;
         }
         seekItem = Subitems.Find(x => x is TableFooter);
         if (seekItem != null)
         {
             return false;
         }
         return item.IsValid();
     }
     return false;
 }
开发者ID:npuBug,项目名称:fb2epub,代码行数:59,代码来源:Table.cs


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