`
文章列表

Random usage

public class RandomTest {       public static void main(String[] args)       {             Random rand1 = new
Timer typical usage   new Timer().schedule(new TimerTask() {     public void run() {        System.err.println("Aborting");         System.exit(0);     }//end of run   }, 5000); //Terminate after 5 seconds   Create a infinite running timer, execute one every second Timer timer = ...
public class AllTests {         public static Test suite()       {  
package xmldom;import java.io.FileInputStream;import java.io.FileNotFoundException;import java.io.FileOutputStream;import java.io.IOException;import java.io.InputStream;import java.util.Iterator;import java.util.LinkedList;import java.util.List;import org.jdom.Document;import org.jdom.Element;import ...
Method one:               DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();             DocumentBuilder builder = factory.newDocumentBuilder();             //This part is to solve issue of unknown host url -- springframework.org             builder.setEntityResolver(new En ...
Readonly file can't be changed, and can be deleted.
How to load a properties?   Simply add the properties’ folder into the classpath, then load it in this way.   private static Properties prop = new Properties(); prop.load(Constants.class.getClassLoader().getResourceAsStream(
  1.如何获得当前文件路径  常用:  字符串类型:System.getProperty("user.dir");  综合:
==sending out message=============== factory = new TibjmsTopicConnectionFactory(Constants.url); connection = factory.createTopicConnection(Constants.user, Constants.pass); session = connection.createTopicSession(false
hibernate logging   ## print all generated SQL to the consolehibernate.show_sql true   ## format SQL in log and consolehibernate.format_sql  true   ## add comments to the generated SQLhibernate.use_sql_comments  true  

Sybase Query Plan

  To see query plans, use: set showplan on   To stop displaying query plans, use: set showplan off      
1) Must use ApplicationContext, can't use BeanFactory. Example: ApplicationContext factory = new ClassPathXmlApplicationContext(new String[]{"spring.xml"});   2) BeanNameAutoProxyCreator bean must include property as below. <property name="proxyTargetClass"
http://www.blogjava.net/Unmi http://lijinjoseji.wordpress.com/
generate env classpath from lib folder for libfile in $(find lib/*) do     classpath=$classpath:./$libfile done export classpath=$classpath
Tag 35   35 = D      New Order Single Request   35 = G     Modification Request   35 = F      Cancel Request   35 = 8      New Order Single Ack                 New Order Single Reject   35 = 9      Modification Reject
Global site tag (gtag.js) - Google Analytics