Apache Commons project, common component package Introduction

Source: Internet
Author: User

Introduction:The Apache Commons project is designed specifically to share the correct primary goal of building and maintaining reusable Java components. Sharing the correct information is a local collaboration and communication. developers from the entire Apache community work together on projects that are shared by Apache projects and Apache users.

The Apache Commons project consists of three parts:

  • The commons proper-a reusable Java Component Library
  • The commons sandbox-Java component development Workspace
  • The commons dormant-currently inactive Component Library

Commonly used tool kits for developing Java programs:

1. the DBCP component [commons-DBCP]

1. Use Cases

The commons-DBCP package provides support for interaction with relational databases with Multiple Apache projects. Examples include:

  • The Basic Object pool mechanism provided by the commons-pool package. The Commons-DBCP package is dependent on the code.

2. MAVEN dependency

<dependency><groupId>commons-dbcp</groupId><artifactId>commons-dbcp</artifactId><version>1.3</version></dependency>

II. The beanutils component [commons-beanutils]


1. Use Cases

The beanutils component provides easy-to-use packaging of these features. Examples include:

  • Create a Java object model for scripting language interaction (for example, using bean Scripting framework ).
  • Architectural template language processor Web presentations and similar purposes (such as JSP or velocity ).
  • Build a custom tag library, JSP, and xsp environment (such as Jakarta taglibs, struts, and cocoon ).
  • Use XML-based configuration resources (such as ant build scripts, web application deployment descriptors, and Tomcat server. xml files ).

2. MAVEN dependency

<dependency><groupId>commons-beanutils</groupId><artifactId>commons-beanutils</artifactId><version>1.8.3</version></dependency>

III. The net component [commons-net]

1. Use Cases

The Apache commons net Library implements many basic Internet protocols on the client. The purpose of this library is to provide basic protocol access, rather than high-level abstraction.

Supported protocols include:

  • FTP/ftps
  • FTP over HTTP (experimental)
  • NNTP
  • SMTP (s)
  • POP3 (s)
  • IMAP (s)
  • Telnet
  • TFTP
  • Finger
  • Whois
  • REXEC/RCMD/Rlogin
  • Time (rdate) and daytime
  • Echo
  • Discard
  • NTP/SNTP

2. MAVEN dependency

<dependency><groupId>commons-net</groupId><artifactId>commons-net</artifactId><version>3.1</version></dependency>

4. The Commons Lang [commons-lang]

1. Use Cases

The standard Java library does not provide sufficient methods to manipulate its core classes. Apache commons Lang provides these additional methods. Lang provides a series of Java. Lang APIs for auxiliary public facilities, especially string operation methods, basic numeric methods, object reflection, concurrency, creation and serialization, and system performance.

Note: lang3.0 (and later versions) uses different packages (Org. apache. commons. lang3) compared with previous versions (Org. apache. commons. lang), allowing it to be used at the same time and earlier versions.

2. MAVEN dependency

<dependency><groupId>org.apache.commons</groupId>  <artifactId>commons-lang3</artifactId>  <version>3.1</version></dependency>


References:

  • Commons-beanutils component [http://commons.apache.org/proper/commons-beanutils/]
  • Commons-DBCP component [http://commons.apache.org/proper/commons-dbcp/]

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.