Package org.apache.ivy.core.report
Class ResolveReport
- java.lang.Object
-
- org.apache.ivy.core.report.ResolveReport
-
public class ResolveReport extends java.lang.ObjectRepresents a whole resolution report for a module
-
-
Constructor Summary
Constructors Constructor Description ResolveReport(ModuleDescriptor md)ResolveReport(ModuleDescriptor md, java.lang.String resolveId)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddReport(java.lang.String conf, ConfigurationResolveReport report)voidcheckIfChanged()ArtifactDownloadReport[]getAllArtifactsReports()Get every report on the download requests.java.util.List<java.lang.String>getAllProblemMessages()java.util.List<Artifact>getArtifacts()Returns the list of all artifacts which should be downloaded per this resolve To know if the artifact have actually been downloaded use information found in ConfigurationResolveReport.ArtifactDownloadReport[]getArtifactsReports(ModuleRevisionId mrid)ArtifactDownloadReport[]getArtifactsReports(DownloadStatus downloadStatus, boolean withEvicted)Get the report on the download requests.ConfigurationResolveReportgetConfigurationReport(java.lang.String conf)java.lang.String[]getConfigurations()java.util.List<IvyNode>getDependencies()Returns the list of all dependencies concerned by this report as a List of IvyNode ordered from the more dependent to the least onelonggetDownloadSize()The total size of downloaded artifacts, in bytes.longgetDownloadTime()IvyNode[]getEvictedNodes()ArtifactDownloadReport[]getFailedArtifactsReports()Get every report on the download requests.ModuleDescriptorgetModuleDescriptor()java.util.List<ModuleId>getModuleIds()gives all the modules ids concerned by this report, from the most dependent to the least onejava.util.List<java.lang.String>getProblemMessages()java.lang.StringgetResolveId()longgetResolveTime()IvyNode[]getUnresolvedDependencies()booleanhasChanged()Can only be called if checkIfChanged has been calledbooleanhasError()voidoutput(ReportOutputter[] outputters, ResolutionCacheManager cacheMgr, ResolveOptions options)voidsetDependencies(java.util.List<IvyNode> dependencies, Filter<Artifact> artifactFilter)voidsetDownloadSize(long size)voidsetDownloadTime(long elapsedTime)voidsetProblemMessages(java.util.List<java.lang.String> problems)voidsetResolveTime(long elapsedTime)ModuleDescriptortoFixedModuleDescriptor(IvySettings settings, java.util.List<ModuleId> midToKeep)
-
-
-
Constructor Detail
-
ResolveReport
public ResolveReport(ModuleDescriptor md)
-
ResolveReport
public ResolveReport(ModuleDescriptor md, java.lang.String resolveId)
-
-
Method Detail
-
addReport
public void addReport(java.lang.String conf, ConfigurationResolveReport report)
-
getConfigurationReport
public ConfigurationResolveReport getConfigurationReport(java.lang.String conf)
-
getConfigurations
public java.lang.String[] getConfigurations()
-
hasError
public boolean hasError()
-
output
public void output(ReportOutputter[] outputters, ResolutionCacheManager cacheMgr, ResolveOptions options) throws java.io.IOException
- Throws:
java.io.IOException
-
getModuleDescriptor
public ModuleDescriptor getModuleDescriptor()
-
getEvictedNodes
public IvyNode[] getEvictedNodes()
-
getUnresolvedDependencies
public IvyNode[] getUnresolvedDependencies()
-
getFailedArtifactsReports
public ArtifactDownloadReport[] getFailedArtifactsReports()
Get every report on the download requests.- Returns:
- the list of reports, never
null
-
getAllArtifactsReports
public ArtifactDownloadReport[] getAllArtifactsReports()
Get every report on the download requests.- Returns:
- the list of reports, never
null
-
getArtifactsReports
public ArtifactDownloadReport[] getArtifactsReports(DownloadStatus downloadStatus, boolean withEvicted)
Get the report on the download requests. The list of download report can be restricted to a specific download status, and also remove the download report for the evicted modules.- Parameters:
downloadStatus- the status of download to retrieve. Set it tonullfor no restriction on the download statuswithEvicted- set it totrueif the report for the evicted modules have to be retrieved,falseto exclude reports from modules evicted in all configurations.- Returns:
- the list of reports, never
null - See Also:
ConfigurationResolveReport.getArtifactsReports(DownloadStatus, boolean)
-
getArtifactsReports
public ArtifactDownloadReport[] getArtifactsReports(ModuleRevisionId mrid)
-
checkIfChanged
public void checkIfChanged()
-
hasChanged
public boolean hasChanged()
Can only be called if checkIfChanged has been called- Returns:
- boolean
-
setProblemMessages
public void setProblemMessages(java.util.List<java.lang.String> problems)
-
getProblemMessages
public java.util.List<java.lang.String> getProblemMessages()
-
getAllProblemMessages
public java.util.List<java.lang.String> getAllProblemMessages()
-
setDependencies
public void setDependencies(java.util.List<IvyNode> dependencies, Filter<Artifact> artifactFilter)
-
getDependencies
public java.util.List<IvyNode> getDependencies()
Returns the list of all dependencies concerned by this report as a List of IvyNode ordered from the more dependent to the least one- Returns:
- The list of all dependencies.
-
getArtifacts
public java.util.List<Artifact> getArtifacts()
Returns the list of all artifacts which should be downloaded per this resolve To know if the artifact have actually been downloaded use information found in ConfigurationResolveReport.- Returns:
- The list of all artifacts.
-
getModuleIds
public java.util.List<ModuleId> getModuleIds()
gives all the modules ids concerned by this report, from the most dependent to the least one- Returns:
- a list of ModuleId
-
setResolveTime
public void setResolveTime(long elapsedTime)
-
getResolveTime
public long getResolveTime()
-
setDownloadTime
public void setDownloadTime(long elapsedTime)
-
getDownloadTime
public long getDownloadTime()
-
setDownloadSize
public void setDownloadSize(long size)
-
getDownloadSize
public long getDownloadSize()
The total size of downloaded artifacts, in bytes.This only includes artifacts actually downloaded to cache (DownloadStatus.SUCCESSFUL), and not artifacts already in cache or used at their original location.
- Returns:
- The total size of downloaded artifacts, in bytes.
-
getResolveId
public java.lang.String getResolveId()
-
toFixedModuleDescriptor
public ModuleDescriptor toFixedModuleDescriptor(IvySettings settings, java.util.List<ModuleId> midToKeep)
-
-