Spring Framework 介绍

Introduction to the Spring Framework

The Spring Framework is a Java platform that provides comprehensive infrastructure support for developing Java applications. Spring handles the infrastructure so you can focus on your application.


Spring Framework 是基于Java的,为开发Java应用提供了完善的基础支持,Spring处理 这些基础,你只需要关注你的应用本身。


Spring enables you to build applications from “plain old Java objects” (POJOs) and to apply enterprise services non-invasively to POJOs. This capability applies to the Java SE programming model and to full and partial Java EE.


Spring 使您可以使用(POJO 简单Java对象)来构建应用,并将企业非侵入式应用到POJO中,这项功能应用于JAVA SE 编程模型 以及 完整或者部分Java EE


Examples of how you, as an application developer, can benefit from the Spring platform:


作为一个应用开发者,你可以从Spring 平台中获益:

  • Make a Java method execute in a database transaction without having to deal with transaction APIs.
  • Make a local Java method a remote procedure without having to deal with remote APIs.
  • Make a local Java method a management operation without having to deal with JMX APIs.
  • Make a local Java method a message handler without having to deal with JMS APIs.

  • 使用Java方法处理数据库事务,不必用关去处理事务处理api
  • 使用本地 java 方法来管理远程,不必要处理远程APIs
  • 使用本地Java 方法进行管理操作,不必要处理JMX APIs
  • 使用本地Java方法处理消息 ,不必要处理JMS APIs。

(依赖注入以及控制反转)Dependency Injection and Inversion of Control

A Java application — a loose term that runs the gamut from constrained, embedded applications to n-tier, server-side enterprise applications — typically consists of objects that collaborate to form the application proper. Thus the objects in an application have dependencies on each other.


Java应用程序-从嵌入式到N 层服务器端企业应用程序,都是典型的由互相依赖的程序对象组成,因此,一个应用程序的各之间是互相依赖的。

Although the Java platform provides a wealth of application development functionality, it lacks the means to organize the basic building blocks into a coherent whole, leaving that task to architects and developers. Although you can use design patterns such as Factory, Abstract Factory, Builder, Decorator, and Service Locator to compose the various classes and object instances that make up an application, these patterns are simply that: best practices given a name, with a description of what the pattern does, where to apply it, the problems it addresses, and so forth. Patterns are formalized best practices that you must implement yourself in your application

– 尽管java 平台提供了丰富报的应用开发方法,但是还缺乏 一个方法用来将 基础模块 组件成一个连贯的整体。将这个任务留给了架构师以及开发者。尽管你可以使用设计模式 (Factory, Abstract Factory, Builder, Decorator, and Service Locator) 构造各种类和对象实例来生成一个应用程序。这些设计模式是简单的:最佳实践的名称,什么样的模式,在什么地方应用,解决什么样的问题等等。模式是实践的模式化,(或者说实践的结晶),所以你必须在你的应用中应用他们

The Spring Framework Inversion of Control (IoC) component addresses this concern by providing a formalized means of composing disparate components into a fully working application ready for use. The Spring Framework codifies formalized design patterns as first-class objects that you can integrate into your own application(s).
Numerous organizations and institutions use the Spring Framework in this manner to engineer robust, maintainable applications.

Spring Framework 的控制反转组件通过提供将不同组件构建成完整的工作应用程序的方法来解决这个问题。 Spring Framework 将形式设计模式 编译为第一类对象 ,你可以将他 集成到你的应用中。大量的组织机构使用Spring Framework 这中方式设计 健壮的可维护的应用程序。

Background

“The question is, what aspect of control are [they] inverting?” Martin Fowler posed this question about Inversion of Control (IoC) on his site in 2004. Fowler suggested renaming the principle to make it more self-explanatory and came up with Dependency Injection.


“问题是,在哪方面进行控制反转?”Martin Fowler在 2004 年在他的网站是提出了 关于这个 关于控制反转的问题。Fowler建议重新命名这个规则,使其看起来更加自明,并提出了依赖注入。

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值