首页
学习
活动
专区
圈层
工具
发布
    • 综合排序
    • 最热优先
    • 最新优先
    时间不限
  • 来自专栏【Android开发基础】

    java.lang.IllegalStateException: You need to use a Theme.AppCompat theme (or descendant) with this a

    报这个错的原因是activity继承了兼容包的类,比如ActionBarActivity,它来自android.support.v7.app.ActionBarActivity

    82820编辑于 2023-02-10
  • 来自专栏韩曙亮的移动开发专栏

    【错误记录】Android 应用运行报错 ( You need to use a Theme.AppCompat theme (or descendant) with this activity. )

    com.example.plugin_hook.MainActivity}: java.lang.IllegalStateException: You need to use a Theme.AppCompat theme (or descendant ZygoteInit.java:858) Caused by: java.lang.IllegalStateException: You need to use a Theme.AppCompat theme (or descendant 之后 , 出现上述问题 ; 解决方案一 : 按照错误提示进行修改 ; 错误信息中 , 给出了解决方案提示 , You need to use a Theme.AppCompat theme (or descendant

    2.8K20编辑于 2023-03-29
  • 来自专栏用户4352451的专栏

    如何使用MySQL关系型数据库存储树结构

    核心字段有三个值: ancestor 父节点的id descendant子节点的ID depth 子节点与父节点之间的深度关系 根据真实数据模型理解一下 ? `depth` TINYINT(5) NOT NULL, PRIMARY KEY (`ancestor`, `descendant`), INDEX `fk_comment_path_descendant_idx 柜1的value为3 delete a from comment_path a join comment_path b on (a.descendant = b.descendant) where b.ancestor delete a from comment_path as a join comment_path as d on a.descendant = d.descendant left join comment_path null; insert into comment_path (ancestor, descendant, depth) select supertree.ancestor, subtree.descendant

    3.5K20发布于 2020-12-16
  • 来自专栏QQ音乐技术团队的专栏

    从源码出发浅析 Android TV 的焦点移动原理(下篇)

    - descendant.mScrollX, descendant.mTop - descendant.mScrollY); ... rect.offset(descendant.mScrollX - descendant.mLeft, descendant.mScrollY - descendant.mTop ); } // 继续往上找 descendant = (View) theParent; theParent = descendant.mParent - descendant.mScrollX, descendant.mTop - descendant.mScrollY); } else { rect.offset(descendant.mScrollX - descendant.mLeft, descendant.mScrollY

    3.9K10发布于 2017-11-06
  • 来自专栏Albert陈凯

    2019-07-15 数据库无限层级分类设计

    以图为例,节点6到它上一级的节点(节点4)距离为1在数据库中存储为ancestor=4,descendant=6,distance=1,到上两级的节点(节点1)距离为2,于是有 ancestor=1,descendant DESC 查询路径,只需要知道 descendant 即可,因为 descendant 字段所在的行就是记录这个节点与其上级节点的关系。 当然 descendant 也要改成自己的。 ancestor,10,distance+1 FROM CategoryTree WHERE descendant=5) 然后就是加入自身连接的记录。 : DELETE FROM CategoryTree WHERE descendant in (select descendant from CategoryTree where ancestor=4)

    4.2K30发布于 2019-07-16
  • 来自专栏吾爱乐享

    python学习之selenium的xpath轴的用法,附案例

    选取当前节点的所有先辈(包括父,祖父,祖祖父等) ancestor-or-self:选取当前节点的所有先辈以及当前节点本身 attribute:选取当前节点的所有属性 child:选取当前节点的所有子元素 descendant :选取当前节点的所有后代元素(包括子,孙等) descendant-or-self:选取当前节点的所有后代元素及当前节点本身 following:选择文本中当前节点结束标签后的所有节点 namespace :选取当前节点的所有后代元素(包括子,孙等) descendant-or-self:选取当前节点的所有后代元素及当前节点本身 following:选择文本中当前节点结束标签后的所有节点 namespace :选取当前节点的所有后代元素(包括子,孙等) descendant-or-self:选取当前节点的所有后代元素及当前节点本身 following:选择文本中当前节点结束标签后的所有节点 namespace 获取当前节点的所有后代元素 browser.find_element_by_xpath(‘//span[@class=”ant-cascader-picker”]/descendant::input’

    1.5K31发布于 2019-12-30
  • 来自专栏测试学习之路

    XPath定位深入学习(二)

    XPath轴(XPath Axes)可定义某个相对于当前节点的节点集:      1、child  选取当前节点的所有子元素      2、parent  选取当前节点的父节点      3、descendant 选取当前节点的所有后代元素(子、孙等)      4、ancestor  选取当前节点的所有先辈(父、祖父等)      5、descendant-or-self  选取当前节点的所有后代元素(子、孙等 一.descendant      descendant选取当前节点的所有后代元素(包括子节点、子孙节点…),descendant (后代)轴包含上下文节点的后代,一个后代是指子节点或者子节点的子节点等等 /descendant::*   选择文档根元素的所有后代.即所有的元素被选择 (加粗代表被选中)    <AAA>      <BBB>           <DDD>                                    </DDD>                </EEE>           </DDD>      </CCC>   </AAA>     //CCC/descendant

    1.1K10发布于 2021-09-17
  • 来自专栏coder修行路

    Python爬虫从入门到放弃(十四)之 Scrapy框架中选择器的用法

    ::img' data=''>, <Selector xpath='<em>descendant</em>-or-self::img' data='<img src ="image2_thumb.jpg">'>, <Selector xpath='<em>descendant</em>-or-self::img' data='<img src="image3_thumb.jpg"> '>, <Selector xpath='<em>descendant</em>-or-self::img' data='<img src="image4_thumb.jpg">'>, <Selector xpath ='<em>descendant</em>-or-self::img' data='<img src="image5_thumb.jpg">'>] In [14]: response.xpath('//div[@id= <Selector xpath='<em>descendant</em>-or-self::a/@href' data='image3.html'>, <Selector xpath='<em>descendant</em>-or-self

    1.4K80发布于 2018-01-04
  • 来自专栏偏前端工程师的驿站

    JS魔法堂:判断节点位置关系

    ){ if (ancestor === descendant) return true; ancestor = ancestor.nodeType === 9 ? ) && function(ancestor, descendant){ if (ancestor === descendant) return true; ancestor = ancestor.documentElement (ancestor.compareDocumentPosition(descendant) & 16); } || rNative.test(document.createRange) && function (ancestor, descendant){ if (ancestor === descendant) return true; var r1 = document.createRange( || descendant);  三、总结                                 尊重原创,转载请注明

    6.1K50发布于 2018-01-18
  • 来自专栏测试学习之路

    XPath定位深入学习(三)

    一. descendant-or-self descendant-or-self跟descendant类似,多了节点本身。   /AAA/BBB/descendant-or-self::*    选择/AAA/BBB本身及所有后代元素    <AAA>      <BBB>           <DDD>                                    </DDD>                </EEE>           </DDD>      </CCC>       //CCC/descendant-or-self

    84510发布于 2021-09-22
  • 来自专栏测试学习之路

    xpath定位深入学习(一)

    ancestor-or-self  选取当前节点的所有先辈(父、祖父等)以及当前节点本身(不包含叔叔伯伯 //*[@id="content_views"]/p[51]/span[1]/ancestor-or-self::div descendant 选取当前节点的所有后代元素(子、孙等) //*[@id="content_views"]/descendant::span descendant-or-self选取当前节点的所有后代元素(子、孙等)以及当前节点本身 //*[@id="content_views"]/p[51]/descendant-or-self::p preceding   选取文档中当前节点的开始标签之前的所有节点 //*[@id="content_views

    74730发布于 2021-09-14
  • 来自专栏冰霜的软件测试技术分享

    XPATH定位(进阶篇)

    xpath轴是什么 w3cschool上的定义如下: 语法 轴名称::节点测试[谓语] 具体应用 (1)descendant表示取当前节点的所有后代元素 定位百度首页的“百度一下”按钮 可以看到 , <input>标签的父元素是标签, 而标签的父元素是<form>标签, 所以可以通过先定位<form>标签, 然后利用descendant定位<input>标签 xpath路径如下 : xpath= "//form[@id='form']/descendant::input[@id='su']" 含义://form[@id='form']表示找到id属性为'form'的<form> 标签,descendant::input表示找到<form>标签的所有后代<input>标签,然后通过[@id='su']精准定位到id属性为'su'的<input>标签 把路径放到浏览器控制台,按下Ctrl

    1.9K20编辑于 2022-03-15
  • 来自专栏吾爱乐享

    python学习之xpath使用案例总结

    选取当前节点的所有先辈(包括父,祖父,祖祖父等) ancestor-or-self:选取当前节点的所有先辈以及当前节点本身 attribute:选取当前节点的所有属性 child:选取当前节点的所有子元素 descendant :选取当前节点的所有后代元素(包括子,孙等) descendant-or-self:选取当前节点的所有后代元素及当前节点本身 following:选择文本中当前节点结束标签后的所有节点 namespace child::*:选取当前节点的所有子元素 attribute::*:选取当前节点的所有属性 child::text():选取当前节点的所有文本子节点 child::node():选取当前节点的所有子节点 descendant "文本"]') browser.execute_script('arguments[0].scrollIntoView()',org_target)#拖到指定的位置 time.sleep(1) #使用descendant 定位所有的后代元素 browser.find_element_by_xpath('//div[@class="fixed-d-picker-icon"]/descendant::input').click

    1.8K10发布于 2019-12-30
  • 来自专栏计算机视觉与深度学习基础

    Leetcode 236. Lowest Common Ancestor of a Binary Tree

    v and w as the lowest node in T that has both v and w as descendants (where we allow a node to be a descendant Another example is LCA of nodes 5 and 4 is 5, since a node can be a descendant of itself according to

    68290发布于 2018-01-12
  • 来自专栏计算机视觉与深度学习基础

    Leetcode 235. Lowest Common Ancestor of a Binary Search Tree

    v and w as the lowest node in T that has both v and w as descendants (where we allow a node to be a descendant Another example is LCA of nodes 2 and 4 is 2, since a node can be a descendant of itself according to

    73690发布于 2018-01-12
  • 来自专栏技术社区

    解决react-router-dom V6路由嵌套时,子路由无法显示的问题

    警告提示:You rendered descendant <Routes> (or called useRoutes()) at "/home" (under <Route path="/home">) <Route path="/home" element={<Commonview />}></Route> Commonview组件 子路由页面无法显示,并警告:You rendered descendant

    3.1K30编辑于 2022-09-23
  • 来自专栏柠檬先生

    jquery 层级选择器

    ; $("ancestor descendant") 选择给定的祖先元素的所有后代元素 ancestor:任何有效的选择器; descendant: 一个用来筛选子元素的选择器;

    1.2K100发布于 2018-01-19
  • 来自专栏walterlv - 吕毅的博客

    XML 的 XPath 语法

    :package/child::metadata/child::id /child::package/child::metadata/child::node()[1] /child::package/descendant-or-self ::dependency 这里的 child、descendant-or-self 是轴描述语法,除了这两个,还有这些: child 子节点 可以省略不写 attribute 属性 可以用 @ 来缩写 descendant 子孙节点 descendant-or-self 自身引用及子孙节点,可以用 // 来缩写 parent 父节点 可以用 ..

    1.5K20发布于 2018-09-18
  • 来自专栏思考是一种快乐

    Scrapy 入门教程

    >>> response.css('title') [<Selector xpath=u'descendant-or-self::title' data=u'<title>Quotes to Scrape world/page/1/">world

    找到quote >>> response.css("div.quote") [<Selector xpath=u"descendant-or-self normalize-space(@class), ' '), ' quote ')]" data=u'<div class="quote" itemscope itemtype="h'>, <Selector xpath=u"descendant-or-self normalize-space(@class), ' '), ' quote ')]" data=u'<div class="quote" itemscope itemtype="h'>, <Selector xpath=u"descendant-or-self 选组第一个 >>> response.css("div.quote")[0] <Selector xpath=u"descendant-or-self::div[@class and contains(

99020发布于 2019-09-23
  • 来自专栏Reck Zhang

    LeetCode 0235 - Lowest Common Ancestor of a Binary Search Tree

    p and q as the lowest node in T that has both p and q as descendants (where we allow a node to be a descendant null,3,5], p = 2, q = 4 Output: 2 Explanation: The LCA of nodes 2 and 4 is 2, since a node can be a descendant

    31320发布于 2021-08-11
  • 领券