java 知识点总结.ppt_第1页
java 知识点总结.ppt_第2页
java 知识点总结.ppt_第3页
java 知识点总结.ppt_第4页
java 知识点总结.ppt_第5页
已阅读5页,还剩10页未读 继续免费阅读

下载本文档

版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领

文档简介

java知识点总结 The WhitePaper Buzzwords Simple简洁Object Oriented面向对象的Distributed分布式 对网络文件处理 Robust健壮性 可靠性 减少程序错误 Secure安全性 沙盒 Architecture neutral结构中立 JVM WORA Portable可移植Interpreted解释型High performance高效性Multithreaded并发性Dynamic动态性 JVMJavaVirtualMachineJDKJavaDevelopmentKitJREJavaRuntimeEnvironmentIDEIntegratedDevelopmentEnvironment集成开发环境GUIGraphicalUserInterfaceApplicationvs Applet enumtypeenumSize SMALL MEDIUM LARGE EXTRA LARGE Sizes Size MEDIUM stringStringgreeting Hello Strings greeting substring 1 3 StringBuilderbuilder newStringBuilder builder append a builder append cat StringcompletedString builder toString PredefinedclassDateb day newDate System out println b day gettheyearSystem out println b day getYear System out println b day getMonth factorymethodsLocalDaterightNow LocalDate now LocalDatenewYearsEve LocalDate of 2017 9 25 System out println rightDate getYear System out println rightDate getMonthValue System out println rightDate getDayOfMonth Specialfinal只生成一次static Astaticfieldisalsocalledaclassfield whichmeansthatthestaticfieldissharedacrossallitsobjects 只保存最近赋值 所有对象通用 类似unionstaticfinal Astaticfinalfieldisasharedconstantacrossallitsobjects commentMulti linecomments likethis Documentationcomments ThisisthefirstsampleprograminCoreJavaChapter3 version1 011997 03 22 authorGaryCornell Literalshex0 xCAFEoctal031Binary0b1111 0100 0010 0100 0000Double POSTIVE INFINITY正无穷大Double NEGATIVE INFINITY负无穷大 UsesupertoavoidrecursivecallpublicclassManagerextendsEmployee privatedoublebonus publicdoublegetSalary returnsuper getSalary bonus Object TheCosmicSuperclassAnyobjectorarrayreferencecanbestoredinavariableoftypeObject System out println Employee obj1 getName Objectobj2 newint 10 int obj2 0 1 System out println int obj2 0 ArrayListArrayListeList newArrayList eList add LiLei PrintthesecondoneSystem out println eList get 1 SetthesecondtoJerryeList set 1 Jerry SpecialobjectsIntegerDouble LambdaArrays sort intArr newComparator publicintcompare Integeri Integerj returnj i Arrays sort stus s1 s2 s2 getName compareTo s1 getName System out println Arrays toString stus ComparatorArrays sort stus newComparator publicintcompare Students1 Students2 returns2 getName compareTo s1 getName ScreenSizeDimensionscreenSize Toolkit getDefaultToolkit getScreenSize Resizable drawDrawLineDrawRectDrawOval LayoutFlowLayoutThedefaultlayoutofJPanelBorderLayoutThedefaultlayoutofJFrameGridLayout ScrollPaneJScrollPanescrollPane newJScrollPane textArea setbackgroundcolorbRed addActionListener e getContentPane setBackground Color red bPanel setBackground Color red ChangefontActionListenercheckbListener event intmode 0 if bold isSelected mode Font BOLD if italic isSelected mode Font ITALIC label setFont newFont Serif mode FONTSIZE CombpBoxJComboBoxfaceCombo newJComboBox faceCombo addItem Serif faceCombo addItem SansSerif faceCombo addItem Monospaced faceCombo addItem Dialog faceCombo addItem DialogInput faceCombo addActionListener event label setFont newFont String faceCombo getSelectedItem Font PLAIN 24 menubarsetJMenuBar toolbarJToolBarbar newJToolBar DefineabuttonwithagiveniconJButtonbtnRed newJButton newImageIcon red ball gif SpecifytheactionbtnRed addActionListener e label setForeground Color red Addthebuttontothebarbar add btnRed MessageDialog JOptionPane showMessageDialog null HellotheDialogWorld ConfirmDialog ReturnsanintegerindicatingtheoptionselectedbytheuserYes 0No 1Cancel 2Close 1 intretConfirm JOptionPane showConfirm

温馨提示

  • 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
  • 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
  • 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
  • 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
  • 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
  • 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
  • 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

评论

0/150

提交评论