JAVAĿ¼ѡÔñ¿òµÄ½â¾ö°ì·¨
FileDialogÖ»ÄÜÑ¡ÔñÎļþ¶ø²»ÄÜÑ¡ÔñÎļþ¼Ð¡£JFileChooserÓÖÌ«´ó£¬²»Ì«ºÃ¿´£¬¹Äµ·Á˺ÃÒ»»áÖÕÓÚ½â¾öÁË¡£
¼Ç¼һϹؼü²¿·Ö´úÂ룬ÒÔ±¸²éÓá£
final JButton choose=new JButton("Ñ¡Ôñ´æ´¢ÎļþĿ¼");
final JTextField dir=new JTextField();
final JFileChooser chooser=new JFileChooser();
chooser.setFileSelectionMode(JFileChooser.DIRECTORIES_ONLY);
choose.addActionListener(new ActionListener(){
public void actionPerformed(ActionEvent event){
int returnValue=chooser.showOpenDialog(SearchFrame.this);
if (returnValue==JFileChooser.APPROVE_OPTION) {
File file=chooser.getSelectedFile();
dir.setText(file.getAbsolutePath());
path=file.getAbsolutePath();
}else {
JOptionPane.showMessageDialog(null, "ÇëÊÖ¶¯ÊäÈëĿ¼");
return;
}
}
Ïà¹ØÎĵµ£º
JavaÖУ¬Jniµ÷ÓÃDLLÎļþÊÔÑé
ËùÓÐÎļþ¾ùÔÚE:\·¾¶Ï¡£
°²×°jdk1.6.0_07
°²×°ÁËVC++6.0
µÚÒ»²½£¬
HelloWorld.java
µÚ¶þ²½£¬
E:\>javac HelloWorld.java
µÃµ½
HelloWorld.class
µÚÈý²½£¬
E:\>javah HelloWorld
µÃµ½
HelloWorld.h
µÚËIJ½£¬
±àдһ¸öCÎļþ
HelloWorldImp.c
µÚÎå²½£¬
ʹÓÃcl±àÒ ......
ÖÕÓÚÈ¡µÃÁËÒ»µãСµÄ½øÕ¹£¬¿ØÖÆÓÐЧÁË£¬ÖÁÉÙÊÇÎÒµãÔËÐУ¬ÌõÂë»ú³öÎÄ×ÖÀ²£¡Ê×Ïȷdz£¸Ðл²Î¿¼Á½ÆªÎÄÕµÄ×÷Õߣ¬²»µ¥ÊÇ·ÖÏíÁ˾Ñ飬¸üÖØÒªµÄÊǸøÎÒÆôµÏ£¬
ÈÃÎÒÓÐÁËÐÅÐľõµÃÕâ¼þÊ¿ÉÒÔÕâô×ö¡£È»ºóÎÒҪ˵µÄÊÇJNative.jarºÜºÃÓã¬Ê¡È¥ÁË´«Í³JNIÄÇô¶à·ÇJava³ÌÐòÔ±µÄ¹¤×÷£¨µ«ÊÇÈç¹ûÕû¸ö¹¤×÷Íê³É
ºó£¬ÎÒ»¹ÊÇÏë¿´×ÅjnativeµÄÔ´Âë£¬Ó ......
JAVAµÄÉè¼ÆÔÔò
1. ½Ó¿Ú¸ôÀëÔÔò£¨ISP£ºInterface Segregation Principle£©
¶¨Ò壺ʹÓöà¸öרÃŵıÈʹÓõ¥Ò»µÄ×ܽӿÚÒªºÃ¡£Ò²¿ÉÒÔ˵£º½¨Á¢µ¥Ò»½Ó¿Ú£¬²»Òª½¨Á¢Ó·Ö×ÅÓ´óµÄ½Ó¿Ú¡£
ISPµÄÁ½ÖÖ¶¨Ò壺
¡ó “Clients should not be forced to depend upon interfaces that they don't u ......
1¡¢ http://java.sun.com/ ;;(Ó¢ÎÄ)
SunµÄJavaÍøÕ¾£¬ÊÇÒ»¸öÓ¦¸Ã¾³£È¥¿´µÄµØ·½¡£²»Óöà˵¡£
2¡¢ http://www-900.ibm.com/developerWorks/cn/ ;;
IBMµÄdeveloperWorksÍøÕ¾£¬Ó¢ÓïºÃµÄÖ±½ÓÈ¥Ó¢ÎÄÖ÷Õ¾µã¿´¡£ÕâÀï²»µ«ÊÇÒ»¸ö¼«ºÃµÄÃæÏò¶ÔÏóµÄ·ÖÎöÉè¼ÆÍøÕ¾£¬Ò²ÊÇWeb Services£¬Java£¬Linux¼«ºÃµÄÍøÕ¾¡£Ç¿ÁÒÍƼö£¡£¡£¡
3¡¢ h ......