These two days in debugging Java serial Communication Code, found a problem, in the program run up, send serial signal to the device, Observation Task Manager, Javaw.exe is still running.
If rerun, will be prompted "portinuseexception", that is, the
reflection mechanism The operation of the pairs of arrays 1
gets the class object of the array and the associated properties and methods
public class classarraydemo{public
static void Main (String args[]) throws exception{
int temp[] = {1,2,3};/
13. 1 set interface
13. 1. 1 separating the interface of the set from the implementation
As is often the case with modern data structure class libraries, the Java Collection Class library separates interfaces (interface) from implementations
Java non-repetitive random number generation
Import java.util.*;public class test{public static void Main (string[] args) {Generate [0-n] a random number that is not repeated/ST To save these random numbersArrayList list = new ArrayList ();int n = 10
One of the most immediate advantages of Windows system Services (NT services) versus ordinary applications is that the system can run directly after booting without the user logging on to the system. In fact, the system used as a server usually does
This article a lot of transfer other people's place, the younger brother does the work is to everybody work summary according to this process may save everybody several 10 minutes or longer time ~
Brief process : Export jar files or apply tools to
This code implements the method of connecting the native database.
Operation Steps:
1, access the Control Panel, open "Administrative tools → data Source (ODBC)", pop-up "ODBC Data Source Administrator", in the User DSN tab, click the selected name
Original works, allow reprint, reprint, please be sure to hyperlink form to indicate the original source of the article, author information and this statement. Otherwise, legal liability will be held.
Custom negative exception Classes class MyException extends Exception {public myexception (String msg)//construction Method {super (MSG);//Invoke the constructor method of the Exception exception class The class Test {public int devide (int x,int y)
This example continues the orchard farm in the last factory method. This time, the farm company introduced plastic shed technology to plant tropical (tropical) fruits and vegetables in the greenhouse.
1. Abstract factory instance class diagram
QR code generation principle (i)
First, what is QR code
QR code is a kind of matrix two-dimensional code, developed by Denso (Japan Electric installation) company, standardized by JIS and ISO. The QR code looks in fact on many occasions already can
Inheritance implements the reuse of code, the abstract class takes into account the purpose of code reuse and the realization of polymorphism, interface is a 100% abstract class, its existence is purely for polymorphism.
Polymorphic, the sample
Only use to Hashtable, HashMap, HashSet, Linkedhashmap and so on to pay attention to hashcode, other places hashcode useless. (So understanding is not necessarily right)
Whether the two objects are equal or not requires hashcode () equality, and
Java known two locations latitude and longitude distance (very accurate)
Package com.lbnet.lzx.util;
public class GoogleMap {Private static final Double Earth_radius = 6378.137;private static Double rad (double D){return d * math.pi/180.0;}/*** ???
Exception Log
caused By:java.net.SocketException:No buffer space available (maximum connections reached?): Connect at Java.net.Tw Ostacksplainsocketimpl.socketconnect (Native method) at Java.net.AbstractPlainSocketImpl.doConnect (
Struts2 and Spring consolidation
The integration of 1.STRUTS2 and spring is mostly about handing the action in struts to spring to manage the first step: adding an Action class bean to the spring's configuration file (Useraction, for example) can
1. What does the "static" keyword mean? Whether a private or static method can be overridden in Java (override).
Answer: the "static" keyword indicates that a member variable or a member method can be accessed without an instance variable of the
When you recently used httpclient in your project, you encountered this problem with the following exception information:
Info: Retrying Connect2013-1-23 16:36:31 Org.apache.http.impl.client.DefaultRequestDirector TryconnectInfo: I/O exception (java.
Quote Encyclopedia
The builder pattern is a form of design that separates the construction of a complex object from its representation, allowing the same build process to create different representations.
Practical Range
1 The algorithms for
definition: captures the internal state of an object without damaging the encapsulation, and saves the state outside the object. You can then restore the object to its previously saved state
Type: object behavior pattern
class Diagram:
When we are
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