JAVA×¢½â
AnnotationÊÇJava5¡¢6Ö»ºóµÄÐÂÌØÕ÷£¨ÖÐÎijÆÖ®Îª×¢½â£©£¬²¢ÇÒÔ½À´Ô½¶àµÄµÃµ½ÁËÓ¦Ó㬱ÈÈçSpring¡¢Hibernate3¡¢Struts2¡¢iBatis3¡¢JPA¡¢JUnitµÈµÈ¶¼µÃµ½Á˹㷺ӦÓã¬Í¨¹ýʹÓÃ×¢½â£¬´úÂëµÄÁé»îÐÔ´ó´óÌá¸ß¡£
ÕâЩ¶¼ÊÇʹÓñðÈ˶¨ÒåµÄ×¢½â£¬Ò»°ã×¢½âµÄʹÓö¼ÊÇÔÚһЩ»ù´¡¿ò¼Ü»òÕßÀà¿âÖÐÀ´¶¨ÒåµÄ£¬Òò´ËºÜÉÙ¼û¹ýÓÐÈË×Ô¼ºÈ¥Ð´Ò»¸ö×¢½â³öÀ´²¢Ê¹ÓÃÔÚ³ÌÐòÖУ¬Òò´Ë×¢½âµÄʹÓó£³£¸øÈ˸оõºÜÉñÃØ£¬Õâ¾ÍΪÄã½Ò¿ª×¢½âµÄÃæÉ´¡£
×¢½âµÄÉñÃØÖ®´¦ÔÚÓÚ£ºÍ¨¹ýÀàËÆ×¢Ê͵ķ½Ê½£¬¿ÉÒÔ¿ØÖƳÌÐòµÄһЩÐÐΪ£¬ÔËÐÐʱµÄ״̬£¬¿ÉÒÔΪ³ÉÔ±¸³Öµ£¬×öÅäÖÃÐÅÏ¢µÈµÈ£¬Óë³£¹æ±àÂë˼ά´óÏྶͥ¡£
Ö»ÓñðÈ˶¨ÒåºÃµÄ×¢½âÊǸ㲻¶®ÕâЩÎÊÌâµÄ£¬ÒªÏëÕæÕýÖªµÀ×¢½âÄÚ²¿µÄÃØÃÜ£¬Òª×Ô¼º¶¨Òå×¢½â£¬È»ºóÔÚ³ÌÐòÖлñȡע½âÐÅÏ¢£¬Äõ½×¢½âÐÅÏ¢ºó£¬¾Í¿ÉÒÔΪÎÒËùÓÃÁË¡£
ÏÂÃæÎÒ¼òµ¥ÑÝʾÏÂÈýÀà×¢½âµÄÓ÷¨£ºÀà×¢½â¡¢·½·¨×¢½â¡¢×ֶΣ¨Ò²³ÆÖ®Óò£©×¢½âµÄ¶¨ÒåÓëÊÊÓ㬲¢¿´¿´ÈçºÎ»ñȡע½âµÄÐÅÏ¢¡£
Ò»¡¢¶¨Òå×¢½â
package lavasoft.anntest;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
/**
* Àà×¢½â
*
* @author leizhimin 2009-12-18 14:15:46
*/
@Retention(RetentionPolicy.RUNTIME)
@Target(ElementType.TYPE)
public @interface MyAnnotation4Class {
public String msg();
}
package lavasoft.anntest;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
/**
* ·½·¨×¢½â
*
* @author leizhimin 2009-12-18 14:16:05
*/
@Retention(RetentionPolicy.RUNTIME)
@Target(ElementType.METHOD)
public @interface MyAnnotation4Method {
public String msg1();
&
Ïà¹ØÎĵµ£º
JAVAÖлù±¾±äÁ¿¹²°üÀ¨£ºbyte,short,int,long,float,double,char,boolean,ÔÚ³ÌÐòÖÐÓõÄ×îÆÕ±é£¬×î¶à£¬µ«ÊÇËüÃǵÄһЩ¹Ø¼üÒ²¾³£±»ÎÒÃÇËùºöÂÔ£¬ÎÒ½ñÌì×ܽáÁËһϣ¬ÌùÔÚÕâÀï¡£¡£¡£
1.
±äÁ¿¶¨Ò壺
Ò»¸öÓɱêʶ·û¶¨ÒåµÄÊý¾ÝÏ°üÀ¨ÀàÐÍ¡¢Ãû³ÆºÍÖµÈý¸ö²¿·Ö
2.
±äÁ¿·ÖÀࣺ
Àà ......
¡¾Ö÷Ìâ¡¿ Java»ù±¾Êý¾ÝÀàÐ͵ÄÔËËã
¡¾¹Ø¼ü×Ö¡¿java »ù±¾Êý¾ÝÀàÐÍ
¡¾ÎÊÌâÃèÊö¡¿Çë¿´Èç¹ûÒ»¶Î´úÂë,Èç¹û²»ÔÚeclipseÀïÔËÐÐ,Çëд³öÊä³ö½á¹û
public static void main(String[] args) {
&n ......
Java´®¿ÚͨѶ
´®ÐÐͨѶÐÒéÓкܶàÖÖ£¬ÏñRS232£¬RS485£¬RS422£¬ÉõÖÁÏÖ½ñÁ÷ÐеÄUSBµÈ¶¼ÊÇ´®ÐÐͨѶÐÒé¡£¶ø´®ÐÐͨѶ¼¼ÊõµÄÓ¦ÓÃÎÞ´¦²»ÔÚ¡£¿ÉÄÜ´ó¼Ò¼ûµÄ×î¶à¾ÍÊǵçÄԵĴ®¿ÚÓëModemµÄͨѶ¡£¼ÇµÃÔÚPC»ú¸Õ¿ªÊ¼ÔÚÖйúÁ÷ÐÐÆðÀ´Ê±(´óÔ¼ÊÇÔÚ90Äê´úǰÎåÄê)£¬ÄÇʱÉõÖÁÓÐÈËÓÃÒ»Ìõ´®ÐÐÏß½øÐÐÁ½Ì¨µçÄÔÖ®¼äµÄÊý ......
package fileTest;
import java.io.*;
public class FileOperate {
public FileOperate() {
}
public static void main(String args[]){
// newFolder("D:/100");
moveFile("e:/978 ......
ÎÒ²»ÖªµÀÕâÆªÎÄÕµÄ×÷ÕßÊÇË£¬µ«ÎÒÖªµÀ£¬Ëû¶ÔjavaÓÐÒ»ÖÖºÜÉîµÄÀí½â£¬ÆäʵÎÄÕÂÖв¢Ã»ÓÐÌåÏÖ³ö×÷Õß¶Ôjava¼¼ÊõÉî²ãÀí½â£¬µ«ÊÇ´ÓÎÄÖеÄÿһ¾ä»°ÖУ¬ÎÒ¸ÐÊܵ½ÁËһЩ¶«Î÷¡£ÕâÊÇһƪºÜºÃµÄÎÄÕ£¬Ò²¿ÉÒÔ°ïÖúºÜ¶àÈËÃÔãµÄÈ˽â¾öÎÊÌâ¡£´øÀ´ºÍ´ó¼Ò·ÖÏíһϡ£
ǰ²»¾ÃCSDN¿¯µÇÁËһƪ¡¶CÓïÑÔÒѾËÀÁË¡·µÄÎÄÕ£¬ÒýÆðÁËһЩÕùÂÛ¡£ÆäʵÄÇÆ ......