public abstract class AbstractTraceForURIProvider<SomeFile,Trace extends AbstractTrace> extends java.lang.Object implements ITraceForURIProvider
Modifier and Type | Class and Description |
---|---|
protected static class |
AbstractTraceForURIProvider.CachedTraces |
protected static interface |
AbstractTraceForURIProvider.PersistedTrace |
Constructor and Description |
---|
AbstractTraceForURIProvider() |
Modifier and Type | Method and Description |
---|---|
protected abstract SomeFile |
asFile(AbsoluteURI absoluteURI,
IProjectConfig project)
Obtain the file representation from the given URI.
|
protected SomeFile |
asFile(SourceRelativeURI srcRelativeDerivedResource,
IProjectConfig project) |
protected abstract java.util.List<AbstractTraceForURIProvider.PersistedTrace> |
findInverseTraceFiles(SomeFile sourceFile)
Find all the trace files that have been written for the given source file.
|
protected abstract AbstractTraceForURIProvider.PersistedTrace |
findPersistedTrace(SomeFile generatedFile)
Find the persisted trace information for the given generated file.
|
protected abstract AbsoluteURI |
getAbsoluteLocation(SomeFile file)
Returns the absolute location from the given file representation.
|
protected AbsoluteURI |
getGeneratedLocation(AbstractTraceForURIProvider.PersistedTrace trace)
Compute the location of the generated file from the given trace file.
|
protected SourceRelativeURI |
getGeneratedUriForTrace(IProjectConfig projectConfig,
AbsoluteURI absoluteSourceResource,
AbsoluteURI generatedFileURI,
ITraceURIConverter traceURIConverter) |
protected abstract IProjectConfig |
getProjectConfig(SomeFile sourceFile)
Find the project configuration for the given generated file.
|
protected IResourceServiceProvider |
getServiceProvider(AbsoluteURI absoluteSourceResource) |
protected TraceFileNameProvider |
getTraceFileNameProvider() |
Trace |
getTraceToSource(AbsoluteURI absoluteDerivedResource,
IProjectConfig project)
Returns the trace information to the sources that were used as input for the given derived resource.
|
Trace |
getTraceToSource(SomeFile generatedFile) |
Trace |
getTraceToSource(SourceRelativeURI srcRelativeDerivedResource,
IProjectConfig project)
Returns the trace information to the sources that were used as input for the given derived resource.
|
Trace |
getTraceToTarget(AbsoluteURI absoluteSourceResource,
IProjectConfig project)
Returns the trace information to the targets that were generated from the given source.
|
Trace |
getTraceToTarget(SomeFile sourceFile,
AbsoluteURI absoluteSourceResource,
IProjectConfig projectConfig) |
Trace |
getTraceToTarget(SourceRelativeURI srcRelativeSourceResource,
IProjectConfig project)
Returns the trace information to the targets that were generated from the given source.
|
protected abstract Trace |
newAbstractTrace(SomeFile file)
Instantiate a new instance of the trace and associate the locate information with the given file.
|
protected abstract Trace newAbstractTrace(SomeFile file)
protected abstract SomeFile asFile(AbsoluteURI absoluteURI, IProjectConfig project)
protected abstract AbsoluteURI getAbsoluteLocation(SomeFile file)
protected SomeFile asFile(SourceRelativeURI srcRelativeDerivedResource, IProjectConfig project)
protected abstract java.util.List<AbstractTraceForURIProvider.PersistedTrace> findInverseTraceFiles(SomeFile sourceFile)
protected abstract AbstractTraceForURIProvider.PersistedTrace findPersistedTrace(SomeFile generatedFile)
protected abstract IProjectConfig getProjectConfig(SomeFile sourceFile)
public Trace getTraceToSource(AbsoluteURI absoluteDerivedResource, IProjectConfig project)
ITraceForURIProvider
null
if no such data is available for the given storage.getTraceToSource
in interface ITraceForURIProvider
absoluteDerivedResource
- the resource whose source trace is requested. May not be null
.project
- the project that contains the derived resource. May not be null
.null
.public Trace getTraceToSource(SourceRelativeURI srcRelativeDerivedResource, IProjectConfig project)
ITraceForURIProvider
null
if no such data is available for the given storage.getTraceToSource
in interface ITraceForURIProvider
srcRelativeDerivedResource
- the resource whose source trace is requested. May not be null
.project
- the project that contains the derived resource. May not be null
.null
.public Trace getTraceToTarget(AbsoluteURI absoluteSourceResource, IProjectConfig project)
ITraceForURIProvider
null
if no such data is available for the given storage.getTraceToTarget
in interface ITraceForURIProvider
absoluteSourceResource
- the resource whose target trace is requested. May not be null
.project
- the project that contains the derived resource. May not be null
.null
.public Trace getTraceToTarget(SourceRelativeURI srcRelativeSourceResource, IProjectConfig project)
ITraceForURIProvider
null
if no such data is available for the given storage.getTraceToTarget
in interface ITraceForURIProvider
srcRelativeSourceResource
- the resource whose target trace is requested. May not be null
.project
- the project that contains the resource. May not be null
.null
.public Trace getTraceToTarget(SomeFile sourceFile, AbsoluteURI absoluteSourceResource, IProjectConfig projectConfig)
protected SourceRelativeURI getGeneratedUriForTrace(IProjectConfig projectConfig, AbsoluteURI absoluteSourceResource, AbsoluteURI generatedFileURI, ITraceURIConverter traceURIConverter)
protected IResourceServiceProvider getServiceProvider(AbsoluteURI absoluteSourceResource)
protected AbsoluteURI getGeneratedLocation(AbstractTraceForURIProvider.PersistedTrace trace)
protected TraceFileNameProvider getTraceFileNameProvider()