`
文章列表

trie树

import java.util.ArrayList; import java.util.Iterator; import java.util.List; public class Trie { private Vertex root;// 一个Trie树有一个根节点 // 内部类 protected class Vertex {// 节点类 protected int words; protected int prefixes; protected Vertex[] edges;// 每个节点包含26个子节点(类型为自身) Vertex() { words = ...

POM.xml配置详解

<project xmlns="http://maven.apache.org/POM/4.0.0 "      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance "      xsi:schemaLocation="http://maven.apache.org/POM/4.0.0http://maven.apache.org/maven-v4_0_0.xsd ">      <!--父项目的坐标。如果项目中没有规定某个元素的值,那么父项目中的对应值即为项 ...

BDB

    博客分类:
  • BDB
package com.yihaodian.testBDB; import java.io.File; import com.sleepycat.je.Database; import com.sleepycat.je.DatabaseConfig; import com.sleepycat.je.DatabaseEntry; import com.sleepycat.je.DatabaseException; import com.sleepycat.je.Environment; import com.sleepycat.je.EnvironmentConfig; import com. ...
List<String> res1 = new ArrayList<String>(); try { // 根据网卡取本机配置的IP,适用于Windows和Linux Enumeration netInterfaces = NetworkInterface.getNetworkInterfaces(); while (netInterfaces.hasMoreElements()) { NetworkInterface ni = (NetworkInterface) netInterfaces.nextElement(); E ...
★ 数组转Collection 使用Apache Jakarta Commons Collections:    1. import org.apache.commons.collections.CollectionUtils;      2.      3. String[] strArray = {"aaa", "bbb", "ccc"};      4. List strList = new ArrayList();      5. Set strSet = new HashSet();      6. Collec ...
Global site tag (gtag.js) - Google Analytics