org.apache.maven.report.projectinfo
Class ProjectInfoReportUtils
java.lang.Object
org.apache.maven.report.projectinfo.ProjectInfoReportUtils
public class ProjectInfoReportUtils
- extends java.lang.Object
Utilities methods.
- Since:
- 2.1
- Version:
- $Id: ProjectInfoReportUtils.java 679614 2008-07-24 23:43:50Z vsiveton $
- Author:
- Vincent Siveton
Method Summary |
static java.lang.String |
getArtifactIdCell(java.lang.String artifactId,
java.lang.String link)
|
static java.lang.String |
getArtifactUrl(org.apache.maven.artifact.factory.ArtifactFactory factory,
org.apache.maven.artifact.Artifact artifact,
org.apache.maven.project.MavenProjectBuilder mavenProjectBuilder,
java.util.List remoteRepositories,
org.apache.maven.artifact.repository.ArtifactRepository localRepository)
|
static java.lang.String |
getInputStream(java.net.URL url,
org.apache.maven.settings.Settings settings)
Get the input stream using ISO-8859-1 as charset from an URL. |
static java.lang.String |
getInputStream(java.net.URL url,
org.apache.maven.settings.Settings settings,
java.lang.String encoding)
Get the input stream from an URL. |
static boolean |
isArtifactUrlValid(java.lang.String url)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ProjectInfoReportUtils
public ProjectInfoReportUtils()
getInputStream
public static java.lang.String getInputStream(java.net.URL url,
org.apache.maven.settings.Settings settings)
throws java.io.IOException
- Get the input stream using ISO-8859-1 as charset from an URL.
- Parameters:
url
- not nullsettings
- not null to handle proxy settings
- Returns:
- the ISO-8859-1 inputstream found.
- Throws:
java.io.IOException
- if any- See Also:
getInputStream(URL, Settings, String)
getInputStream
public static java.lang.String getInputStream(java.net.URL url,
org.apache.maven.settings.Settings settings,
java.lang.String encoding)
throws java.io.IOException
- Get the input stream from an URL.
- Parameters:
url
- not nullsettings
- not null to handle proxy settingsencoding
- the wanted encoding for the inputstream. If null, encoding will be "ISO-8859-1".
- Returns:
- the inputstream found depending the wanted encoding.
- Throws:
java.io.IOException
- if any
getArtifactUrl
public static java.lang.String getArtifactUrl(org.apache.maven.artifact.factory.ArtifactFactory factory,
org.apache.maven.artifact.Artifact artifact,
org.apache.maven.project.MavenProjectBuilder mavenProjectBuilder,
java.util.List remoteRepositories,
org.apache.maven.artifact.repository.ArtifactRepository localRepository)
- Parameters:
factory
- not nullartifact
- not nullmavenProjectBuilder
- not nullremoteRepositories
- not nulllocalRepository
- not null
- Returns:
- the artifact url or null if an error occurred.
getArtifactIdCell
public static java.lang.String getArtifactIdCell(java.lang.String artifactId,
java.lang.String link)
- Parameters:
artifactId
- not nulllink
- could be null
- Returns:
- the artifactId cell with or without a link pattern
- See Also:
AbstractMavenReportRenderer#linkPatternedText(String)
isArtifactUrlValid
public static boolean isArtifactUrlValid(java.lang.String url)
- Parameters:
url
- not null
- Returns:
true
if the url is valid, false
otherwise.
Copyright © 2005-2009 The Apache Software Foundation. All Rights Reserved.