HttpClient - JDepend Source Code Analysis

##### Overview

- Features
- News
- Status
- Download
- Wiki
- User Guide
  - Authentication Guide
  - Character Encodings
  - Cookies
  - Exception Handling
  - Logging Guide
  - Methods
  - Optimization Guide
  - Preference Architecture
  - Redirects Handling
  - Sample Code
  - SSL Guide
  - Threading
  - Trouble Shooting
  - Tutorial
- Developer Guide

##### Project Documentation

- About
- Project Info
- Project Reports
  - Change Log
  - Developer Activity
  - File Activity
  - JavaDocs
  - JavaDoc Report
  - JavaDoc Warnings Report
  - Metrics
  - Unit Tests
  - Source Xref
  - Test Xref
  - Project License
  - Task List
- Development Process

##### Legend

- External Link
- Opens in a new window

## Metric Results

[ summary] [ packages] [ cycles] [ explanations]

The following document contains the results of a JDependmetric analysis. The various metrics are defined at the bottom of this document.

## Summary

[ summary] [ packages] [ cycles] [ explanations]

Package | TC | AC | CC | AC | EC | A | I | D
--- | --- | --- | --- | --- | --- | --- | --- | ---
org.apache.commons.httpclient | 68 | 7 | 61 | 6 | 15 | 0.1 | 71% | 18%
org.apache.commons.httpclient.auth | 20 | 5 | 15 | 1 | 10 | 0.25 | 91% | 16%
org.apache.commons.httpclient.cookie | 23 | 4 | 19 | 1 | 6 | 0.17 | 86% | 3%
org.apache.commons.httpclient.methods | 15 | 3 | 12 | 1 | 8 | 0.2 | 89% | 9%
org.apache.commons.httpclient.methods.multipart | 8 | 3 | 5 | 1 | 7 | 0.38 | 88% | 25%
org.apache.commons.httpclient.params | 9 | 2 | 7 | 5 | 5 | 0.22 | 50% | 28%
org.apache.commons.httpclient.protocol | 9 | 3 | 6 | 1 | 10 | 0.33 | 91% | 24%
org.apache.commons.httpclient.util | 15 | 0 | 15 | 6 | 11 | 0 | 65% | 35%

## Packages

[ summary] [ packages] [ cycles] [ explanations]

### org.apache.commons.httpclient

Afferent Couplings | Efferent Couplings | Abstractness | Instability | Distance
--- | --- | --- | --- | ---
6 | 15 | 10% | 71% | 18%

Abstract Classes | Concrete Classes | Used by Packages | Uses Packages
--- | --- | --- | ---
Credentials HttpConnectionManager HttpMethod HttpMethodBase HttpMethodRetryHandler MethodRetryHandler ResponseConsumedWatcher | AutoCloseInputStream ChunkedInputStream ChunkedOutputStream CircularRedirectException ConnectMethod ConnectTimeoutException ConnectionPoolTimeoutException ContentLengthInputStream Cookie DefaultHttpMethodRetryHandler DefaultMethodRetryHandler Header HeaderElement HeaderGroup HostConfiguration HttpClient HttpClientError HttpConnection HttpConstants HttpContentTooLargeException HttpException HttpHost HttpMethodBase$1 HttpMethodDirector HttpParser HttpRecoverableException HttpState HttpStatus HttpURL HttpVersion HttpsURL InvalidRedirectLocationException MultiThreadedHttpConnectionManager MultiThreadedHttpConnectionManager$1 MultiThreadedHttpConnectionManager$ConnectionPool MultiThreadedHttpConnectionManager$ConnectionSource MultiThreadedHttpConnectionManager$HostConnectionPool MultiThreadedHttpConnectionManager$HttpConnectionAdapter MultiThreadedHttpConnectionManager$HttpConnectionWithReference MultiThreadedHttpConnectionManager$ReferenceQueueThread MultiThreadedHttpConnectionManager$WaitingThread NTCredentials NameValuePair NoHttpResponseException ProtocolException ProxyClient ProxyClient$1 ProxyClient$ConnectResponse ProxyClient$DummyConnectionManager ProxyHost RedirectException SimpleHttpConnectionManager StatusLine URI URI$DefaultCharsetChanged URI$LocaleToCharsetMap URIException UsernamePasswordCredentials Wire WireLogInputStream WireLogOutputStream | org.apache.commons.httpclient.auth org.apache.commons.httpclient.cookie org.apache.commons.httpclient.methods org.apache.commons.httpclient.params org.apache.commons.httpclient.protocol org.apache.commons.httpclient.util | java.io java.lang java.lang.ref java.lang.reflect java.net java.security java.util org.apache.commons.codec org.apache.commons.codec.net org.apache.commons.httpclient.auth org.apache.commons.httpclient.cookie org.apache.commons.httpclient.params org.apache.commons.httpclient.protocol org.apache.commons.httpclient.util org.apache.commons.logging

### org.apache.commons.httpclient.auth

Afferent Couplings | Efferent Couplings | Abstractness | Instability | Distance
--- | --- | --- | --- | ---
1 | 10 | 25% | 91% | 16%

Abstract Classes | Concrete Classes | Used by Packages | Uses Packages
--- | --- | --- | ---
AuthPolicy AuthScheme AuthSchemeBase CredentialsProvider RFC2617Scheme | AuthChallengeException AuthChallengeParser AuthChallengeProcessor AuthScope AuthState AuthenticationException BasicScheme CredentialsNotAvailableException DigestScheme HttpAuthRealm HttpAuthenticator InvalidCredentialsException MalformedChallengeException NTLM NTLMScheme | org.apache.commons.httpclient | java.lang java.security java.util javax.crypto javax.crypto.spec org.apache.commons.codec.binary org.apache.commons.httpclient org.apache.commons.httpclient.params org.apache.commons.httpclient.util org.apache.commons.logging

### org.apache.commons.httpclient.cookie

Afferent Couplings | Efferent Couplings | Abstractness | Instability | Distance
--- | --- | --- | --- | ---
1 | 6 | 17% | 86% | 3%

Abstract Classes | Concrete Classes | Used by Packages | Uses Packages
--- | --- | --- | ---
CookieAttributeHandler CookiePolicy CookieSpec CookieVersionSupport | Cookie2 CookieOrigin CookiePathComparator CookieSpecBase IgnoreCookiesSpec MalformedCookieException NetscapeDraftSpec RFC2109Spec RFC2965Spec RFC2965Spec$1 RFC2965Spec$Cookie2DomainAttributeHandler RFC2965Spec$Cookie2MaxageAttributeHandler RFC2965Spec$Cookie2PathAttributeHandler RFC2965Spec$Cookie2PortAttributeHandler RFC2965Spec$Cookie2VersionAttributeHandler RFC2965Spec$CookieCommentAttributeHandler RFC2965Spec$CookieCommentUrlAttributeHandler RFC2965Spec$CookieDiscardAttributeHandler RFC2965Spec$CookieSecureAttributeHandler | org.apache.commons.httpclient | java.lang java.text java.util org.apache.commons.httpclient org.apache.commons.httpclient.util org.apache.commons.logging

### org.apache.commons.httpclient.methods

Afferent Couplings | Efferent Couplings | Abstractness | Instability | Distance
--- | --- | --- | --- | ---
1 | 8 | 20% | 89% | 9%

Abstract Classes | Concrete Classes | Used by Packages | Uses Packages
--- | --- | --- | ---
EntityEnclosingMethod ExpectContinueMethod RequestEntity | ByteArrayRequestEntity DeleteMethod FileRequestEntity GetMethod HeadMethod InputStreamRequestEntity MultipartPostMethod OptionsMethod PostMethod PutMethod StringRequestEntity TraceMethod | org.apache.commons.httpclient.methods.multipart | java.io java.lang java.util org.apache.commons.httpclient org.apache.commons.httpclient.methods.multipart org.apache.commons.httpclient.params org.apache.commons.httpclient.util org.apache.commons.logging

### org.apache.commons.httpclient.methods.multipart

Afferent Couplings | Efferent Couplings | Abstractness | Instability | Distance
--- | --- | --- | --- | ---
1 | 7 | 38% | 88% | 25%

Abstract Classes | Concrete Classes | Used by Packages | Uses Packages
--- | --- | --- | ---
Part PartBase PartSource | ByteArrayPartSource FilePart FilePartSource MultipartRequestEntity StringPart | org.apache.commons.httpclient.methods | java.io java.lang java.util org.apache.commons.httpclient.methods org.apache.commons.httpclient.params org.apache.commons.httpclient.util org.apache.commons.logging

### org.apache.commons.httpclient.params

Afferent Couplings | Efferent Couplings | Abstractness | Instability | Distance
--- | --- | --- | --- | ---
5 | 5 | 22% | 50% | 28%

Abstract Classes | Concrete Classes | Used by Packages | Uses Packages
--- | --- | --- | ---
HttpParams HttpParamsFactory | DefaultHttpParams DefaultHttpParamsFactory HostParams HttpClientParams HttpConnectionManagerParams HttpConnectionParams HttpMethodParams | org.apache.commons.httpclient org.apache.commons.httpclient.auth org.apache.commons.httpclient.methods org.apache.commons.httpclient.methods.multipart org.apache.commons.httpclient.protocol | java.io java.lang java.util org.apache.commons.httpclient org.apache.commons.logging

### org.apache.commons.httpclient.protocol

Afferent Couplings | Efferent Couplings | Abstractness | Instability | Distance
--- | --- | --- | --- | ---
1 | 10 | 33% | 91% | 24%

Abstract Classes | Concrete Classes | Used by Packages | Uses Packages
--- | --- | --- | ---
ControllerThreadSocketFactory$SocketTask ProtocolSocketFactory SecureProtocolSocketFactory | ControllerThreadSocketFactory ControllerThreadSocketFactory$1 DefaultProtocolSocketFactory Protocol ReflectionSocketFactory SSLProtocolSocketFactory | org.apache.commons.httpclient | java.io java.lang java.lang.reflect java.net java.util javax.net javax.net.ssl org.apache.commons.httpclient org.apache.commons.httpclient.params org.apache.commons.httpclient.util

### org.apache.commons.httpclient.util

Afferent Couplings | Efferent Couplings | Abstractness | Instability | Distance
--- | --- | --- | --- | ---
6 | 11 | 0% | 65% | 35%

Abstract Classes | Concrete Classes | Used by Packages | Uses Packages
--- | --- | --- | ---
None | DateParseException DateParser DateUtil EncodingUtil ExceptionUtil HttpURLConnection IdleConnectionHandler IdleConnectionTimeoutThread LangUtils ParameterFormatter ParameterParser TimeoutController TimeoutController$TimeoutException URIUtil URIUtil$Coder | org.apache.commons.httpclient org.apache.commons.httpclient.auth org.apache.commons.httpclient.cookie org.apache.commons.httpclient.methods org.apache.commons.httpclient.methods.multipart org.apache.commons.httpclient.protocol | java.io java.lang java.lang.reflect java.net java.security java.text java.util org.apache.commons.codec org.apache.commons.codec.net org.apache.commons.httpclient org.apache.commons.logging

## Cycles

[ summary] [ packages] [ cycles] [ explanations]

Package | Cyclic Dependencies
--- | ---
org.apache.commons.httpclient | org.apache.commons.httpclient.util org.apache.commons.httpclient
org.apache.commons.httpclient.auth | org.apache.commons.httpclient.util org.apache.commons.httpclient org.apache.commons.httpclient.util
org.apache.commons.httpclient.cookie | org.apache.commons.httpclient org.apache.commons.httpclient.util org.apache.commons.httpclient
org.apache.commons.httpclient.methods | org.apache.commons.httpclient org.apache.commons.httpclient.util org.apache.commons.httpclient
org.apache.commons.httpclient.methods.multipart | org.apache.commons.httpclient.util org.apache.commons.httpclient org.apache.commons.httpclient.util
org.apache.commons.httpclient.params | org.apache.commons.httpclient org.apache.commons.httpclient.util org.apache.commons.httpclient
org.apache.commons.httpclient.protocol | org.apache.commons.httpclient.util org.apache.commons.httpclient org.apache.commons.httpclient.util
org.apache.commons.httpclient.util | org.apache.commons.httpclient org.apache.commons.httpclient.util

## Explanations

[ summary] [ packages] [ cycles] [ explanations]

The following explanations are for quick reference and are lifted directly from the original JDepend documentation.

Term | Description
--- | ---
Number of Classes | The number of concrete and abstract classes (and interfaces) in the package is an indicator of the extensibility of the package.
Afferent Couplings | The number of other packages that depend upon classes within the package is an indicator of the package's responsibility.
Efferent Couplings | The number of other packages that the classes in the package depend upon is an indicator of the package's independence.
Abstractness | The ratio of the number of abstract classes (and interfaces) in the analyzed package to the total number of classes in the analyzed package. The range for this metric is 0 to 1, with A=0 indicating a completely concrete package and A=1 indicating a completely abstract package.
Instability | The ratio of efferent coupling (Ce) to total coupling (Ce / (Ce + Ca)). This metric is an indicator of the package's resilience to change. The range for this metric is 0 to 1, with I=0 indicating a completely stable package and I=1 indicating a completely instable package.
Distance | The perpendicular distance of a package from the idealized line A + I = 1. This metric is an indicator of the package's balance between abstractness and stability. A package squarely on the main sequence is optimally balanced with respect to its abstractness and stability. Ideal packages are either completely abstract and stable (x=0, y=1) or completely concrete and instable (x=1, y=0). The range for this metric is 0 to 1, with D=0 indicating a package that is coincident with the main sequence and D=1 indicating a package that is as far from the main sequence as possible.
Cycles | Packages participating in a package dependency cycle are in a deadly embrace with respect to reusability and their release cycle. Package dependency cycles can be easily identified by reviewing the textual reports of dependency cycles. Once these dependency cycles have been identified with JDepend, they can be broken by employing various object-oriented techniques.