Understanding of the components

1.J2EE the container acts as a middleware role. The main container includes:

WEB container :

To a state in which application components (JSP, SERVLET) provides an environment in which JSP, SERVLET interface interaction more directly to the vessel environment variable, not a concern other system problems. There are WEB server to achieve. For example: TOMCAT, WEBLOGIC, WEBSPHERE like. The container provides an interface WEB APPLICATION strict compliance with the standard J2EE specification. We comply with the above standard WEB server is called WEB container in J2EE.

EJB container :

Enterprise  the Java bean  container. More industries characteristics. He offers to EJB components running within a variety of management functions. As long as the J2EE specification EJB into the container, the container will be immediately performed efficient management. And can be obtained by ready-made system-level service interface. Such as mail services, transaction management . WEB and EJB containers in principle is much the same, the difference is more isolated from the external environment. More WEB container is dealing with HTTP-based requests. The EJB container is not. It is more of a database with other services to deal with. But they are the interact with the outside world in order to reduce light application of the burden of the program. For example SERVLET do not care about the details of HTTP, a direct reference to environment variables session, request, response on the line, EJB do not care about the database connection speed, various transaction control, directly done by the container.

2. objects , classes , package , module , component , container , frame , these java belongs to them have one thing in common : to accommodate . But what is the relationship and linkages between them with each other it ? 

Object (Object) :

      In the java world , the object is achieved by the properties and methods are the things that have static and dynamic properties correspond .

 

Class (Class) :

      It is used to describe the same abstract concept of a type of the object .

The relationship between objects and classes :

      Abstract class is a set of objects with common attributes and behaviors of the name, and the object is a real example of a class.

Component ( the Component ) :

      Component is an abstract concept , it can be understood as a combination of a number of classes that meet certain specifications together constitute an assembly. He can provide certain functions. J2EE is, what the servlet , JSP, JavaBean , the EJB is a component. But actually they are like, but they have special rules.

  And relation component classes : composite class constituent elements meet certain specifications .

Container (Container) :

        Also called container assembly container , the component is a special container component, which may contain other components. We can put components on the component container. Conversely, if a component is not a component container, which can not contain other components.

      Container assembly is an assembly component so that a container can be placed in another vessel assembly. It has a component container makes things complicated again. We can put components on the component containers , you can also put in another container component assembly container, thus forming a hierarchical structure components. 

     We can imagine become a common component of eggs, and the components of the container imagination become baskets. Then , the eggs can be placed in small baskets, baskets and other small eggs can turn on the big basket. Thus , the basket can be egg, there can be other basket , it can be understood from the following hand drawing . 

Alternatively the computer generated text: a basket (vessel) eggs (assembly) O a.  .., less Bu O 0

 The relationship between container and components : the container is a special component , may contain components other components .

Framework ( Framework ):

Is the application of certain semi-finished products, is a set of components for you to choose your own complete system . The Java framework is a collection of classes and interfaces, to complete a series of programs through these classes and interfaces to achieve coordination. Framework is also called the development of semi-finished products, it does not provide the entire WEB everything applications, but with the framework, we can concentrate on developing the business logic without having to be concerned about its technology as well as ancillary business logic. We know Structs and Spring is to express on behalf of the framework and business layers.

Relations framework and components :

It is a bundle composed of the frame assembly .

Architecture :

Objects software architecture describes the abstract structure of the system components directly. The connection between the various components are relatively clear and detailed description of the communication between the components. In the implementation phase, these abstract components are refined to the actual component, such as a class or a specific object. In the field of object-oriented, with connections between components typically interface () to achieve.

The relationship between architecture and framework :

Framework is not architecture. Determine the overall structure of the system architecture, hierarchical division, cooperation between the different parts and other design considerations. Framework more specific than architecture , more emphasis on technical suspected. For the same architecture (such as Web development in MVC ), it can be achieved by a variety of frame.

If the relationship comprises or receiving according to these concepts summary , obtained following a map , 

Alternatively the computer generated text: Architecture Framework (1) frame (2) container assembly class object "type L dibutylamino

Transfer: https://blog.csdn.net/ReyzeLamp/article/details/81003900

Guess you like

Origin www.cnblogs.com/sjxbg/p/11165438.html