Java ÖеÄIO
<!--
@page { margin: 0.79in }
P { margin-bottom: 0.08in }
-->
JavaÖеÄ
io
ÎÒ¶ÔÁ÷µÄÀí½âÊÇ£ºÔ´µ½Ä¿µÄµØµÄ¹ì¼££¬ËùÒÔÁ÷µÄÒ»¶ËÊÇÊý¾ÝÔ´£¨ÊäÈëÁ÷£©»òÕß½ÓÊÕÆ÷£¨Êä³öÁ÷£©£¬ÁíÒ»¶ËÊÇ
ioÖеÄij¸öÀࣻÕâÀï˵Ã÷Ï£¬
Scanner
²»ÊÇ
ioÀ࣬Õâ¸ö´ÓËüµÄµ¼Èë°ü¾Í¿ÉÒÔ¿´³ö£¨
java.util.Scanner£©
,ÎÒµÄÀí½â
ScannerÊǸö·½±ãÊäÈë²Ù×÷µÄ¹¤¾ßÀࣻ
ÎÒ°ÑÁ÷·ÖΪ
4À࣬×Ö½Ú¼¶£¬×Ö·û¼¶£¬¶ÔÏ󼶣¬ÆäËû£»
Ò»£¬×Ö½Ú¼¶
1.ÎļþÊäÈë
/Êä³öÁ÷£¨
FileInputStream/FileOutputStream£©
2×Ö½ÚÊý×éÊäÈë
/Êä³öÁ÷£¨
ByteArrayInputStream/ByteArrayOutputStream£©
3.Êý¾ÝÊäÈë
/Êä³öÁ÷£¨
DataInputStream
/DataOutputStream£©
4»º´æÊäÈëÊä³öÁ÷£¨
BufferedInputStream/BufferedOutputStream£©
5»ØÍËÊäÈë×Ö½ÚÁ÷£¨
PushbackInputStream£©
6¸ñʽ»¯Êä³öÁ÷£¨
PrintStream£©
¶þ£¬×Ö·û¼¶
1.FileReader/FileWriter
2.BufferedReader/BufferedWriter
3CharArrayReader/CharArrayWriter
4PushbackReader
5PrintWriter
Èý£¬¶ÔÏó¼¶
ObjectInputStream/ObjectOutputStream
ËÄ£¬ÆäËû
StreamTokenizer
File
RandomAccessFile
ÁíÍ⻹ÓÐÈý¸ö±ê׼ϵͳÁ÷£º
System.in£¨
InputStreamÀàÐÍ£©£¬
System.out£¨
PrintStreamÀàÐÍ£©£¬
System.err£¨
InputStramÀàÐÍ£©£»¿ÉÒÔÓÃ
setIn(in)
,setOut(out),setErr(err)ÖØÐÂÖ¸¶¨²ÎÊýÁ÷Ϊ¶ÔÓ¦±ê×¼Á÷
//ÏÈ´ò¸ö¿ò¼Ü£¬¾ßÌåʵÀýÓÐʱ¼äÁË£¬ÔÙÀ´Ìí¼Ó
Ïà¹ØÎĵµ£º
ListµÄÓ÷¨
List°üÀ¨List½Ó¿ÚÒÔ¼°List½Ó¿ÚµÄËùÓÐʵÏÖÀà¡£ÒòΪList½Ó¿ÚʵÏÖÁËCollection½Ó¿Ú£¬ËùÒÔList½Ó¿ÚÓµÓÐCollection½Ó¿ÚÌṩµÄËùÓг£Ó÷½·¨£¬ÓÖÒòΪListÊÇÁбíÀàÐÍ£¬ËùÒÔList½Ó¿Ú»¹ÌṩÁËһЩÊʺÏÓÚ×ÔÉíµÄ³£Ó÷½·¨£¬Èç±í1Ëùʾ¡£
±í1 List½Ó¿Ú¶¨ÒåµÄ³£Ó÷½·¨¼°¹¦ÄÜ
´Ó±í1¿ÉÒÔ¿´³ö£¬List½Ó¿ÚÌṩµÄÊʺÏÓÚ×ÔÉíµÄ ......
Ôڳɹ¦ÊµÏÖJavaµ÷ÓÃC++Ö®ºó£¬½ÓÏÂÀ´Ïëµ½ÄÜ·ñͨ¹ýJNAʵÏÖJavaµ÷ÓÃFortran£¬½ñÌìÊÔÑéÁËһϣ¬»¹ÊDZȽÏÈÝÒ׵ġ£
ÍøÉÏÓÐÒ»¸öJavaµ÷ÓÃF95µÄÀý×Ó£¬µ«ÊÇÎÒ¿¼ÂDz»½öҪʵÏÖF95µÄµ÷Ó㬻¹ÒªÊµÏÖF77µÄµ÷Óã¬ËùÒÔ·ÑÁËһЩÖÜÕÛ¡£
ÎÊÌâµÄ¹Ø¼üÔÚÓÚF77Ϊ¹ý³ÌÃû×Ô¶¯Ìí¼ÓÁËÒ»¸öβ²¿µÄÏ»®Ïߣ¬ËùÒÔsub1Õâ¸ö¹ý³Ì£¬µ½JavaÒ»¶Ë£¬¾Í±ä³ÉÁËsub1_£¬ ......
Java¿ª·¢Æ½Ì¨µÄÖÖÀàºÜ¶à£¬ÔÚÕâƪÎÄÕÂÖÐÎÒÖ÷ÒªÒÔJ2SEΪÀý×Ó¡£J2SE¼¸ºõÊÇ¿ª·¢ËùÓÐJavaÓ¦ÓóÌÐòµÄ±Ø±¸¡£ËüÖ÷ÒªÊÇÓÉÒ»¸öcompiler(±àÒëÆ÷)£¬Ò»¸öÔËÐл·¾³(runtime environment),ºÍÒ»¸öºËÐĵÄAPIËù¹¹³É¡£ÎÒÃÇÒªÔÙ´ÎҪǿµ÷µÄÊÇ£¬ÄúËù±àдӦÓóÌÐò²¢²»ÊÇÖ±½ÓÔÚÄúµÄ±¾µØ²Ù×÷ϵͳÉÏÖ´ÐÐµÄ ......
ѧϰJavaµÄѧϰ˳Ðò
µÚÒ»½×¶Î(ËĸöÔÂ)
1.j2se
ÃæÏò¶ÔÏó£·â×°¡¢¼Ì³Ð¡¢¶à̬
ÄÚ´æµÄ·ÖÎö
µÝ¹é
¼¯ºÏÀà(Set,List,MapµÄ×ÓÀà)¡¢·ºÐÍ¡¢×Ô¶¯´ò°üÓë½â°ü¡¢Annotation
IOÁ÷(IOÁ÷ºÍÏ̱߳àдһ¸öQQÁÄÌì³ÌÐò)
¶àÏ̡߳¢Ïß³Ìͬ²½
TCP/UDP
AWT¡¢Ê¼þÄ£ÐÍ¡¢ÄäÃûÀà (ÄܲéѯÊý¾Ý¿âÏÔʾÔÚJtableÉÏÃæ)
ÕýÔò± ......
package¡¢import
µÄÏà¹ØÎÊÌâÊÇjavaÖеÄÒ»¸ö²»´ó²»Ð¡µÄÎÊÌ⣬µ«classpathÎÊÌâÈ´ÊÇjavaµÄÒ»¸öÖøÃûµÄÄÑÌâ¡£½ñÍíµÃÏÐÑо¿ÁËһϣ¬ÔÚÕâÀォÎÒµÄÑо¿³É¹û¸ú¸÷λ
ÅóÓÑ·ÖÏíһϡ£ÓÉÓÚͬ°üµÄÇé¿öºÜ¼òµ¥£¬ËùÒÔÕâÀï¾Í²»ÌÖÂÛͬ°üÇé¿ö£¬Ö»ÌÖÂÛ²»Í¬°üºÍ²»Í¬Â·¾¶µÄÇé¿ö¡£ÎªÁËÄÜÈöÁÕ߸üÈÝÒ×Àí½â£¬ÎÒÕâÀïÒÔ¾ÙÀýµÄ·½Ê½À´ËµÃ÷ÎÊ
Ìâ¡£
¡ ......