[Baidu Library course] Java language basics and OOP entry notes 1

Source: Internet
Author: User

 

1. History and origin of Java

Formerly known as Oak, it is designed for embedded system development. Its syntax is basically the same as that of C/C ++.

Ii. Java features

Java consists of four aspects: Java programming language, Java file format, Java Virtual Machine and Java application interface (Java API ).

Two main points:

1. Java inherits the object-oriented core of the C ++ language and is a pure object-oriented language.

2. Java discards pointers and operator overloading, and adds a garbage collection mechanism to implement automatic memory allocation and management.

Major differences with C and C ++

1. Automatic Memory Allocation and recovery. memory management functions or operators in C/C ++ include malloc (), realloc (), free (), and new. delete operators.

2. Global variables outside the class are not supported. They are purely object-oriented and all are constructed based on the class to perform left and right operations in the class.

3. The goto statement is not supported, but the goto statement exists as a reserved Java word without header files.

4. Java is an explanatory language that is compiled into class bytecode and interpreted and executed on a virtual machine. C/C ++ is a compiled language.

5. Enhanced portability. The number of bytes of the type is the same in different systems. C ++ varies according to machine definitions.

JAVAWhat are the basic data types in bytes?

1 byte
Short 2 bytes
Char 2 bytes
Int 4 bytes
Long 8 bytes
Float 4 bytes
Double 8 bytes

Java bytecode http://blog.csdn.net/cyh1111/article/details/5129976

J2EERelated technical indicators:

1. JDBC (Java Database Connectivity) provides a unified interface for connecting to various relational databases. As a data source, it can provide unified access to multiple relational databases, it consists of a group of classes and interfaces written in Java. JDBC provides a standard API for tools/database developers to build more advanced tools and interfaces so that database developers can use pure Java APIs to write database applications, JDBC is also a trademark name.

2. EJB (Enterprise JavaBeans) allows developers to easily create, deploy, and manage cross-platform, component-based Enterprise applications. Java is also worth noting. It is an open standard component architecture, which is independent of the platform but uses the Java language. A JavaBean is a Java class that meets the specifications of JavaBeans. It usually defines a real-world thing or concept. The main features of a JavaBean include attributes, methods, and events. Generally, in a development environment that supports JavaBeans specifications (such as Sun Java Studio and IBM VisualAge for Java), you can operate JavaBean visually or Use JavaBean to construct a new JavaBean. The advantage of JavaBean lies in the portability of Java. EJB extends the JavaBean concept to the Java server component architecture. This model supports multi-layer Distributed Object applications. In addition to JavaBeans, the typical component architecture includes DCOM and CORBA,

3. Java RMI (Java Remote Method Invocation) is used to develop distributed Java applications. A Java object method can be called by a remote Java virtual machine. In this way, remote method activation can occur between the peer and peer, or between the client and server, as long as both applications are written in Java.

4. Java IDL (Java Interface Definition Language) provides seamless interoperability with CORBA (Common Object Request Broker Architecture. This enables Java to integrate heterogeneous business information resources.

5. JNDI (Java Naming and Directory Interface) provides a unified and seamless connection from the Java platform. This interface shields various naming and directory services used by the enterprise network.

6. JMAPI (Java Management API) provides a complete set of objects and methods for the development of systems, networks, and service Management on Heterogeneous Networks.

7. JMS (Java Message Service) provides enterprise Message services, such as reliable Message queue, publish and subscribe communication, and various aspects of Push/Pull technology.

8. JTS (Java transaction Service) provides open standards for accessing transaction processing resources, including transaction processing applications, transaction processing management, and monitoring.

9. JMF (Java Media Framework API) helps developers put audio, video, and other time-based Media in Java applications or applet applets, it provides multimedia developers with tools such as capture, playback, and CODEC. It is an elastic and cross-platform multimedia solution.

10. Annotation (Java Annotation) adds a new feature named Annotation to the released JDK1.5 (tiger. Annotation provides a mechanism to associate program elements such as classes, methods, attributes, parameters, local variables, packages, and metadata. In this way, the compiler can store metadata in the Class file. In this way, virtual machines and other objects can decide how to use these program elements or change their behavior based on the metadata. Spring also has its own annotations, which have different annotation styles. 11. javaFX Sun has just released the official version of JavaFX technology, which enables you to develop rich Internet applications (RIA) using JavaFX programming language ). JavaFX Script Programming Language (JavaFX) is a declarative and staticallytyped (declarative and static) scripting language developed by Sun Microsystems. JavaFX technology has good prospects, including the ability to directly call Java APIs. Because JavaFXScript is a static type, it also has structured code, reusability and encapsulation, such as packages, classes, inheritance and separately compiled and released units, these features make it possible to create and manage large programs using Java technology.

12. JMX (Java Management Extensions) is a framework that embeds Management functions such as applications, devices, and systems. JMX supports flexible development of seamlessly integrated system, network, and service management applications across a series of heterogeneous operating system platforms, system architecture, and network transmission protocols.

13. JPA (Java Persistence API). JPA uses JDK 5.0 annotations or XML to describe the ing relationship between objects and Relational Tables, and persistently stores object objects in the database at runtime.

14. JSP (Java Server Pages) is a dynamic web page technical standard proposed by Sun Microsystems and participated by many companies. JSP technology is a bit similar to ASP technology, it is in the traditional web page HTML file (*. htm ,*. insert the Java program segment (Scriptlet) and JSP tag in html to form a JSP file (*. jsp ). Web applications developed using JSP are cross-platform. They can run both on Linux and other operating systems.

JDK installation and JAVA_HOME and Path configuration are all basic materials. If JDK and eclipse of a higher version are used, many environment variables and paths do not need to be set.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.