Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

Java reflection´úÂëʾÀý

package com.mywebtest.common;
import java.lang.reflect.Array;
import java.lang.reflect.Constructor;
import java.lang.reflect.Field;
import java.lang.reflect.Method;
import java.lang.reflect.Modifier;
/**
 * Java reflection ·Ç³£ÓÐÓã¬ËüʹÀàºÍÊý¾Ý½á¹¹ÄÜ°´Ãû³Æ¶¯Ì¬¼ìË÷Ïà¹ØÐÅÏ¢£¬²¢ÔÊÐíÔÚÔËÐÐ×ŵijÌÐòÖвÙ×÷ÕâЩÐÅÏ¢¡£
 * Java µÄÕâÒ»ÌØÐԷdz£Ç¿´ó£¬²¢ÇÒÊÇÆäËüһЩ³£ÓÃÓïÑÔ£¬Èç C¡¢C++¡¢Fortran »òÕß Pascal µÈ¶¼²»¾ß±¸µÄ¡£
 */
public class ReflectionTest {
    public double d;
   
    public ReflectionTest() {
    }
   
    public ReflectionTest(int a, int b) {
        System.out.println("a = " + a + " b = " + b);
    }
   
    public static void main(String[] args) {
        try {
            //»ñµÃÒ»¸öClass¶ÔÏóµÄ·½·¨Ö®Ò»,»¹ÓÐÁíÒ»ÖÖ·½·¨ÈçÏÂÃæµÄÓï¾ä£ºClass c = int.class;»òÕßClass c = Integer.TYPE;
            Class c = Class.forName(args[0]);
           
            //ÕÒ³öÀàµÄ·½·¨
            Method m[] = c.getDeclaredMethods();
            for (int i = 0; i < m.length; i++) {
                System.out.println(m[i].toString());
            }
           
            //»ñÈ¡¹¹ÔìÆ÷ÐÅÏ¢,»ñÈ¡À๹ÔìÆ÷µÄÓ÷¨ÓëÉÏÊö»ñÈ¡·½·¨µÄÓ÷¨ÀàËÆ
       &


Ïà¹ØÎĵµ£º

javaÁ¬½Ó¸÷ÖÖÊý¾Ý¿âµÄÅäÖÃÎļþд·¨£¨×ª£©

²Î¿¼ÅäÖÃÎļþ
# ʾÀýÅäÖòο¼£¬º­¸Ç¼¸ºõËùÓеÄÖ÷Á÷Êý¾Ý¿â
############# OracleÊý¾Ý¿â ########################
#   Êý¾Ý¿âÇý¶¯Ãû
driver=oracle.jdbc.driver.OracleDriver
#   Êý¾Ý¿âURL(°üÀ¨¶Ë¿Ú£©
dburl=jdbc:oracle:thin:@127.0.0.1:1521:zvfdb
#   Êý¾Ý¿âÓû§Ãû
user=root
#& ......

×·MMÓëJavaµÄ23ÖÖÉè¼Æģʽ

'   ¡¡1¡¢FACTORY—×·MMÉÙ²»ÁËÇë³Ô·¹ÁË£¬Âóµ±À͵ļ¦³áºÍ¿ÏµÂ»ùµÄ¼¦³á¶¼ÊÇMM°®³ÔµÄ¶«Î÷£¬ËäÈ»¿ÚζÓÐËù²»Í¬£¬µ«²»¹ÜÄã´øMMÈ¥Âóµ±ÀÍ»ò¿ÏµÂ»ù£¬Ö»¹ÜÏò·þÎñԱ˵“À´Ëĸö¼¦³á”¾ÍÐÐÁË¡£Âóµ±ÀͺͿϵ»ù¾ÍÊÇÉú²ú¼¦³áµÄFactory
¡¡¡¡¹¤³§Ä£Ê½£º¿Í»§ÀàºÍ¹¤³§Àà·Ö¿ª¡£Ïû·ÑÕßÈκÎʱºòÐèҪijÖÖ²úÆ·£¬Ö»ÐèÏò¹¤³ ......

˼¿¼ PHP+MYSQLµÄOAΪºÎûÓÐJavaµÄֵǮ?


ÏÖÔÚÊг¡ÉϵÄoa»ù±¾ÉϿɹé½áΪÁ½´óÕóÓª£¬¼´phpÕóÓªºÍjavaÕóÓª¡£µ«¶Ô½Ó´¥oa²»¾ÃµÄÓû§À´Ëµ£¬¿´µ½µÄÍùÍùÖ»ÊÇËüÃǵıíÏֻ࣬ÊÇÃ÷ÏԵļ۸ñ²îÒ죬ȴºÜÄÑ¿´³öËüÃÇÖ®¼äµÄʵ¼Ê²îÒì¡£Æäʵ£¬ PHP + MYSQL ²»ÖµÇ®²»½ö½ö¾ÖÏÞÓÚoaÈí¼þ£¬¶øÊÇÕûÌåÉÏPHP + MYSQL¿ª·¢µÄÈí¼þ¶¼²»Èçjava¿ª·¢µÄÈí¼þֵǮ¡£ÎªÊ²Ã´PHP + MYSQL µÄOAΪʲô²»ÖµÇ®Ä ......

JavaʵÏÖÕÛ°ë²éÕÒ(¶þ·Ö²éÕÒ)µÄµÝ¹éºÍ·ÇµÝ¹éËã·¨

ת¡¡£º¡¡http://wintys.blog.51cto.com/425414/94051
/**
*Ãû³Æ:BinarySearch
*¹¦ÄÜ:ʵÏÖÁËÕÛ°ë²éÕÒ(¶þ·Ö²éÕÒ)µÄµÝ¹éºÍ·ÇµÝ¹éËã·¨.
*˵Ã÷:
*     1¡¢ÒªÇóËù²éÕÒµÄÊý×éÒÑÓÐÐò,²¢ÇÒÆäÖÐÔªËØÒÑʵÏÖComparable<T>½Ó¿Ú,ÈçInteger¡¢StringµÈ.
*    2¡¢·ÇµÝ¹é²éÕÒʹÓÃsearch( ......

java¶þ·Ö²éÕÒ

ת £º http://jayzotion.javaeye.com/blog/404084
public class TestBinSearch {   
  
    /**  
     * @param args  
     */  
    public  ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ