Java.util.ArrayList(类):importjava.awt.*;importjava.util.*;publicclassCollectionTest{//List是一个能包含重复元素的已排序的Collection,有时list也称为序列,List第一个元素的下标为0publicStringcolors[]={"red","white","blue"};//定义一个字符数组//构造函数publicCollectionTest(){Array
系统 2019-08-29 22:44:14 1970
Java代码/***Hash算法大全
*推荐使用FNV1算法*@algorithmNone*@authorGoodzzp2006-11-20*@lastEditGoodzzp2006-11-20*@editDetailCreate*/publicclassHashAlgorithms{/***加法hash*@paramkey字符串*@paramprime一个质数*@returnhash结果*/publicstaticintadditiveHash(S
系统 2019-08-12 09:30:14 1970
有时候我们会碰到一些元素不可见,这个时候selenium就无法对这些元素进行操作了。例如,下面的情况:Python页面主要通过“display:none”来控制整个下拉框不可见。这个时候如果直接操作这个下拉框,就会提示:fromseleniumimportwebdriverfromselenium.webdriver.support.selectimportSelectimportos,timedriver=webdriver.Chrome()file_p
系统 2019-09-27 17:52:49 1968
Java中的四种引用强、软、弱和虚引用,对应的生命周期:强>软>弱>虚引用.除强引用外,其他3种引用都需要与ReferenceQueue联合使用,当引用被垃圾回收机制回收的时候,引用会自动放入ReferenceQueue中.WeakReference和SoftReference可以用来做Cashe,文章第二段引用了JavaEye文章,介绍Googlecollection的MapMaker方便生成ConcurrentMap,可以方便的设置map中expire
系统 2019-08-29 23:49:34 1968