Java Reading Study notes

Source: Internet
Author: User
Tags generator

1.pom:maven, project management tools
Files that store jar packages
2.mybatis-generator-core-1.3.2 generate file Generation statement: Java-jar mybatis-generator-core-1.3.2.jar-configfile Generator.xml- Overwrite
Resource, specifically put the configuration file.

Javabea:
JavaBean in the MVC design model, also known as the model layer, in the general program, we call it the data layer, is used to set the data properties and some behavior, and then I will provide get properties and set properties of the Get/set method

J2ee
EE JAVA2 Platform Enterprise Edition (Java 2 platform,enterprise Edition)
The Java EE is a completely different technology architecture from traditional application development, including many components that simplify and standardize the development and deployment of application systems, thus improving portability,
Safety and re-use value. The Java EE core is a set of technical specifications and guidelines, including the various components, service architecture and technical level, all have common standards and specifications,
There is good compatibility between various platforms that follow the Java EE architecture,
To solve the past information products used in the enterprise back end is incompatible with each other, resulting in the enterprise internal or external difficulties of interoperability.

EJB is the Sun's Java EE server-side component model, and the design goal and core application is to deploy distributed applications. In simple terms, the program that has been written
(ie: Class) is packaged and placed on the server for execution. With the advantages of Java cross-platform, distributed systems deployed with EJB technology can be limited to specific platforms.
EJB (Enterprise JavaBean) is part of the Java EE, which defines a standard for developing component-based enterprise multi-application applications.
Features include network service support and core development tools (SDKs). In Java EE, Enterprise Java Beans (EJB), called Java Enterprise Bean, is the core code
The session bean, the entity bean, and the message-driven bean (Messagedriven bean), respectively.

Spring is a lightweight control inversion (IoC) and a facet-oriented (AOP) container framework.
Objective: To solve the complexity of enterprise application development
Function: Use basic JavaBean instead of EJB, and provide more enterprise application function
One of the biggest aims of spring is to make the development of the Java EE easier. At the same time, spring is different from struts, hibernate and other single-layer frames.
It is because spring is committed to providing a unified, efficient way to construct the entire application, and to combine the single-layer framework with the best combination to create a coherent system.
It can be said that spring is a framework that provides a more complete development environment that provides enterprise-class services for Pojo (Plain old Java object) objects
Persistence layer (DAO, data access Layer):
In most cases, especially for enterprise applications, data persistence often means that the data in memory is saved to disk to solidify, while the persistence process is mostly done through a variety of relational databases.

Hibernate Edit

Hibernate is an open-source object-relational mapping framework that provides JDBC with a very lightweight object encapsulation that allows Java programmers to manipulate databases at will using object programming thinking. Hibernate can be applied to any JDBC application, both in Java client applications and in servlet/jsp Web applications, and most revolutionary of all, hibernate can replace CMP in the EE architecture of the EJB application. The task of achieving data persistence.


The term ibatis is derived from the combination of "Internet" and "Abatis" and is a Java-based persistence layer framework. Ibatis provides a durable layer framework that includes SQL maps and Data Access Objects (DAO)

MyBatis is an excellent persistence layer framework that supports common SQL queries, stored procedures, and advanced mappings. MyBatis eliminates the manual setting of almost all JDBC code and parameters and the retrieval of the result set. MyBatis uses simple XML or annotations for configuration and raw mapping, mapping interfaces and Java POJOs (Plain old Java Objects, ordinary Java objects) to records in a database.

Each MyBatis application is primarily using sqlsessionfactory instances, and a sqlsessionfactory instance can be obtained through Sqlsessionfactorybuilder. Sqlsessionfactorybuilder can be obtained from an XML configuration file or an instance of a pre-defined configuration class.

Building an Sqlsessionfactory instance with an XML file is a very simple thing to do. It is recommended to use a CLASSPATH resource (classpath Resource) in this configuration, but you can use any reader instance, including an instance created with a URL that starts with a file path or file://. MyBatis has a utility class----resources, which has many ways to easily load assets from classpath and other locations.
The difference between Ibatis and MyBatis

This difference is not very big, the main difference is that MyBatis simplifies the coding process, do not need to write the DAO implementation class, directly write a DAO excuse, write an XML configuration file, the entire mybatis is configured, that is, the database is connected to the good, Then the service inside the call DAO can be, but ibatis can not, must write DAO implementation class, write what Return Getsqlmapclienttemplate (). queryForList () The Horse of God, So say MyBatis is Ibatis upgrade version, that is, here, do not write DAO's real search now class, there are some differences is the XML inside the SQL statement of the wording of some small changes, but not much

1. Installing the Java JDK (configuring environment variables)
2. Installing the jar (configuring environment variables)
2. Installing Idear Development tools
3. Download the Mevan package (Configure environment variables)

Java Development Kit (JDK) is a free software development kit (Sdk,software Development Kit) released by Sun for Java developers. Now belongs to Oracle Corporation. You can also download OpenJDK, which belongs to the GPL agreement.

As the Java Language SDK, ordinary users do not need to install the JDK to run Java programs, but only to install the JRE (Java Runtime environment). The program developer must install the JDK to compile and debug the program.

Here is the official Oracle JDK, which is the official download page:

The JDK environment variable is configured in version--win8.


Tools/Materials

Jdk-7u51-windows-x64.exe

Method/Step

Depending on the system properties of your computer, if it is a 32-bit system, download the windows-x86 version, or if the 64-bit system downloads the windows-x64 bit. Download the JDK version according to your individual needs, here download the jdk-7u51 version of the 64-bit, below is: http://www.oracle.com/technetwork/java/javase/downloads/index.html

The JDK environment variable is configured in version--win8.


Click Install, select the default installation, do not adjust the location, directly click the next step to install; If you choose to install JRE, select Default

The JDK environment variable is configured in version--win8.


Enter the default installation location for Java, where the default is selected; The red Line part of the path; Copy path:

C:\Program files\java\jdk1.7.0_51

The JDK environment variable is configured in version--win8.


Click on the computer (ie My Computer, WIN8 is this)-"System Properties-Advanced system settings" environment variables

The JDK environment variable is configured in version--win8.

The JDK environment variable is configured in version--win8.

The JDK environment variable is configured in version--win8.


Click "New" under the System variables box to fill in the corresponding variable values:

Java_home C:\Program files\java\jdk1.7.0_51

Jre_home C:\Program Files\java\jre7

CLASSPATH.%java_home%\lib;%java_home%\lib\tools.jar

Edit Path variable, not new, fill in%java_home%\bin;%java_home%\jre\bin;

Note If the original path is not in front of it; (semicolon), add;%java_home%\bin;%java_home%\jre\bin;

The JDK environment variable is configured in version--win8.

The JDK environment variable is configured in version--win8.

The JDK environment variable is configured in version--win8.

The JDK environment variable is configured in version--win8.

The JDK environment variable is configured in version--win8.

6


Click the computer icon, enter CMD in the Path box, press ENTER, or you can use the Win+r key, enter cmd, open a Command line window, enter Java, press ENTER, and, if present, indicate that the installation was successful.


=======================================


MAVEN Installation and Configuration
| Browse: 9260| UPDATED: 2014-04-07 23:27
Installation and configuration of 12Maven installation and configuration of 345Maven 6
Step through Reading
MAVEN is a project-managed Java tool, and in Java EE we can easily manage team-working projects using MAVEN, and now we're learning the Java EE Framework and using MAVEN to manage class libraries, effectively and easily available to other people in your team. Now let's start configuring Maven.

Tools/Materials
System has installed JDK7 version above
Windows operating system
Apache-maven-3.1.1-bin.zip
Method/Step
First, go to the official website to download maven first. Here is the official website address: http://maven.apache.org/download.cgi Please select the latest version of the download, here we download is apache-maven-3.1.1-bin.zip, in the red section
MAVEN Installation and Configuration
Unzip the Apache-maven-3.1.1-bin.zip, and the extracted folder under the apache-maven-3.1.1 folder moved to D:\Java, if there is no Java this folder, please create it yourself.
MAVEN Installation and Configuration
Right-click "Computer", select "Properties", then click "Advanced System Settings", click "Environment variables" to set environment variables, the following system variables need to be configured:
New system variable Maven_home variable value: D:\Java\apache-maven-3.1.1
Edit System variable Path add variable value:;%maven_home%\bin
Finally verify the configuration is successful: With the win key +r, to open the command Line Prompt window, that is, the DOS interface, input MVN--version If the following conditions indicate that the configuration is successful
MAVEN Installation and Configuration
END
Precautions
If configuration errors, make sure that you have correctly configured the JDK environment variables
JDK environment variable Configuration reference experience: http://jingyan.baidu.com/article/ca41422fe3b7261eae99edc6.html
If you feel good, please click to praise Oh!
Maven Configuration method
Http://www.cnblogs.com/good_hans/archive/2010/03/22/1691965.html

After the MAVEN installation is complete, enter it in the start-cmd-command: Mvn-version will show maven related information, which indicates that MAVEN configuration is too old.

Maven Configuration path: D:\Java\apache-maven-3.3.3

Latest Item: D:\WorkSpace\Project\pro1

Java Reading Study notes

Related Article

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.