Package org.apache.maven.internal.impl
Class DefaultProjectBuilder.SourceWrapper
java.lang.Object
org.apache.maven.internal.impl.DefaultProjectBuilder.SourceWrapper
- All Implemented Interfaces:
Source,ModelSource,ModelSource2
- Enclosing class:
DefaultProjectBuilder
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGets a byte stream to the source contents.Provides a user-friendly hint about the location of the source.Returns location of the POM, nevernull.getRelatedSource(String relPath) Returns model source identified by a path relative to this model source POM.
-
Field Details
-
source
-
-
Constructor Details
-
SourceWrapper
SourceWrapper(Source source)
-
-
Method Details
-
getInputStream
Description copied from interface:SourceGets a byte stream to the source contents. Closing the returned stream is the responsibility of the caller.- Specified by:
getInputStreamin interfaceSource- Returns:
- A byte stream to the source contents, never
null. - Throws:
IOException- in case of IO issue
-
getLocation
Description copied from interface:SourceProvides a user-friendly hint about the location of the source. This could be a local file path, a URI or just an empty string. The intention is to assist users during error reporting.- Specified by:
getLocationin interfaceSource- Returns:
- A user-friendly hint about the location of the source, never
null.
-
getRelatedSource
Description copied from interface:ModelSource2Returns model source identified by a path relative to this model source POM. Implementation MUST be able to acceptrelPathparameter values that- use either / or \ file path separator
- have .. parent directory references
- point either at file or directory, in the latter case POM file name 'pom.xml' needs to be used by the requested model source.
- Specified by:
getRelatedSourcein interfaceModelSource2- Parameters:
relPath- is the path of the requested model source relative to this model source POM.- Returns:
- related model source or
nullif no such model source.
-
getLocationURI
Description copied from interface:ModelSource2Returns location of the POM, nevernull.- Specified by:
getLocationURIin interfaceModelSource2
-