Description: A Java class used to take the first letter of Chinese pinyin, for example: The Chinese character "People's Republic of China" takes the Chinese pinyin first letter the result is ZHRMGHG.
The procedure is as follows:
Package GOV.MCA;
/***
An iterator is a pattern that allows the traversal behavior of a data structure of a sequence type to be separated from the object being traversed, that is, we do not need to care what the underlying structure of the sequence is like. Once you get
Today, using the DateFormat parse method, always report a java.text.ParseException:Unparseable date error.
The easiest way to use the idea is:
DateFormat df = new SimpleDateFormat ();Date d = df.parse (new Date (). toString ());
This will cause
-Time format conversion java.text.ParseException:Unparseable Date: "" exception
Time=2013-09-22 string to use
Private final static SimpleDateFormat SimpleDateFormat = new SimpleDateFormat ("Yyyy-mm-dd hh:mm:ss");
Simpledateformat.parse
GAE Java Application Performance Optimization
Reprint please retain the author information:
Author: 88250
Date: February 8, 2011
This article is the author of the development of GAE application performance optimization experience, mainly from the
Recently in the intranet environment to run a large number of data, the Datanode log has the following exception:
2012-12-20 15:40:32,122 ERROR org.apache.hadoop.hdfs.server.datanode.DataNode:DatanodeRegistration ( 10.200.187.193:50010,
I read a really, really interesting article on memory management for the Erlang VM. It is written as a thesis by Jesper Wilhelmsson I thought it might is nice to discuss the differences between Erlang ' s memory setup and Oracle ' Java VM.
As a
JDK provides us with tools to monitor server performance, such as Jconsole, Java VISUALVM, where you can use Java VISUALVM to remotely monitor the performance of WebLogic servers (memory, threads, garbage collection, etc.)
These metrics allow you to
Commonly used EJB, RMI, Web Service, as well as Hessian, NIO, and so on, their advantages and disadvantages compared to the following:
1:ejb
Advantages: Good scalability, strong security, support distributed transaction
Programmers who frequently use the MyEclipse or Eclipse editor to write Java code may often experience a yellow line warning: Dead code; Ordinary programmers will ignore these problems, anyway, without affecting the execution of the program's
Java.util.Scanner is a new feature of JAVA5, and the main function is to simplify text scanning.
Small example:
Resume a TXT file: test.txt
Code:
Import Java.io.File;
Import java.io.FileNotFoundException;
Import Java.util.Scanner;
public
The principle of this pattern is very simple, please see the example below.
1. Class Diagram
2. Java Implementation CodePackage cn.edu.ynu.sei.defaultAdapter;
/**
* Interface a
* This interface has 5 methods, F1~f5
*
* @author 88250
*
The Shutdown event for forms and dialogs in Java swing is nothing more than the windowclosing and windowclosed methods, which are needed if you want to prompt for "exit" when you close or save data. But in the end is to use which method has certain
Import Java.sql.Timestamp;
Import Java.text.SimpleDateFormat;
Import Java.util.Calendar;
Import Java.util.Date;
Import Java.util.GregorianCalendar;
/** * Tool class for type conversions associated with the date type * * @author vinegar * */public
Problem: In Java exception handling, there is a return statement in try {}, so will the code in finally {} After this try be executed, when it is executed, before or after it?
Answer: It will be executed before return.
The code is as follows:
This example is carried out with the example of a roll of dice.
1. Class Diagram
2. Java Implementation Code
Package Cn.edu.ynu.sei.multiton;
/**
* Customers who use dice
*
* @author 88250
* @version 1.0.0, 2007-8-19
*/
public class
There are generally two cases of memory leaks. A situation such as in the C + + language, the allocated memory in the heap, when it is not released, delete all access to the memory (such as pointer redistribution), and the other is to retain the
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service