|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ThirdPartyTool
A tool to load third party files missing files.
We should put here all the logic code written in some mojo and licenseMap...
Field Summary | |
---|---|
static String |
ROLE
Plexus Role |
Method Summary | |
---|---|
void |
addLicense(LicenseMap licenseMap,
org.apache.maven.project.MavenProject project,
org.apache.maven.model.License license)
Add a given license to the given licenseMap for the given project . |
void |
addLicense(LicenseMap licenseMap,
org.apache.maven.project.MavenProject project,
List<?> licenses)
Add a given licenses to the given licenseMap for the given project . |
void |
addLicense(LicenseMap licenseMap,
org.apache.maven.project.MavenProject project,
String licenseName)
Add a license (name and url are licenseName ) to the given licenseMap for the given
project . |
void |
attachThirdPartyDescriptor(org.apache.maven.project.MavenProject project,
File file)
For the given project , attach the given file as a third-party file. |
SortedSet<org.apache.maven.project.MavenProject> |
getProjectsWithNoLicense(LicenseMap licenseMap,
boolean doLog)
From the given licenseMap , obtain all the projects with no license. |
SortedProperties |
loadThirdPartyDescriptorsForUnsafeMapping(String encoding,
Collection<org.apache.maven.project.MavenProject> projects,
SortedSet<org.apache.maven.project.MavenProject> unsafeProjects,
LicenseMap licenseMap,
org.apache.maven.artifact.repository.ArtifactRepository localRepository,
List<org.apache.maven.artifact.repository.ArtifactRepository> remoteRepositories)
|
SortedProperties |
loadUnsafeMapping(LicenseMap licenseMap,
SortedMap<String,org.apache.maven.project.MavenProject> artifactCache,
String encoding,
File missingFile)
|
void |
mergeLicenses(LicenseMap licenseMap,
String... licenses)
For a given licenseMap , merge all licenses . |
File |
resolvThirdPartyDescriptor(org.apache.maven.project.MavenProject project,
org.apache.maven.artifact.repository.ArtifactRepository localRepository,
List<org.apache.maven.artifact.repository.ArtifactRepository> repositories)
Obtain the third party file from the repository. |
Field Detail |
---|
static final String ROLE
Method Detail |
---|
SortedProperties loadThirdPartyDescriptorsForUnsafeMapping(String encoding, Collection<org.apache.maven.project.MavenProject> projects, SortedSet<org.apache.maven.project.MavenProject> unsafeProjects, LicenseMap licenseMap, org.apache.maven.artifact.repository.ArtifactRepository localRepository, List<org.apache.maven.artifact.repository.ArtifactRepository> remoteRepositories) throws ThirdPartyToolException, IOException
encoding
- encoding used to read or write properties filesprojects
- all projects where to read third parties descriptorsunsafeProjects
- all unsafe projectslicenseMap
- license map where to store new licenseslocalRepository
- local repositoryremoteRepositories
- remote repositories
ThirdPartyToolException
- if any
IOException
- if anyvoid attachThirdPartyDescriptor(org.apache.maven.project.MavenProject project, File file)
project
, attach the given file
as a third-party file.
The file will be attached as with a classifier third-parties
and a type properties
.
project
- the project on which to attch the third-party filefile
- the third-party file to attach.File resolvThirdPartyDescriptor(org.apache.maven.project.MavenProject project, org.apache.maven.artifact.repository.ArtifactRepository localRepository, List<org.apache.maven.artifact.repository.ArtifactRepository> repositories) throws ThirdPartyToolException
project
- the projectlocalRepository
- the local repositoryrepositories
- the remote repositories
ThirdPartyToolException
- if anySortedSet<org.apache.maven.project.MavenProject> getProjectsWithNoLicense(LicenseMap licenseMap, boolean doLog)
licenseMap
, obtain all the projects with no license.
licenseMap
- the license map to querydoLog
- a flag to add debug logs
SortedProperties loadUnsafeMapping(LicenseMap licenseMap, SortedMap<String,org.apache.maven.project.MavenProject> artifactCache, String encoding, File missingFile) throws IOException
IOException
void addLicense(LicenseMap licenseMap, org.apache.maven.project.MavenProject project, String licenseName)
licenseName
) to the given licenseMap
for the given
project
.
licenseMap
- the license map where to add the licenseproject
- the projectlicenseName
- the name of the licensevoid addLicense(LicenseMap licenseMap, org.apache.maven.project.MavenProject project, org.apache.maven.model.License license)
license
to the given licenseMap
for the given project
.
licenseMap
- the license map where to add the licenseproject
- the projectlicense
- the license to addvoid addLicense(LicenseMap licenseMap, org.apache.maven.project.MavenProject project, List<?> licenses)
licenses
to the given licenseMap
for the given project
.
licenseMap
- the license map where to add the licensesproject
- the projectlicenses
- the licenses to addvoid mergeLicenses(LicenseMap licenseMap, String... licenses)
licenseMap
, merge all licenses
.
The first value of the licenses
is the license to keep and all other values will be merged into the first
one.
licenseMap
- the license map to mergelicenses
- all the licenses to merge (the first license will be the unique one to kkep)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |