Package org.apache.maven.model.building
Class FileModelSource
java.lang.Object
org.apache.maven.building.FileSource
org.apache.maven.model.building.FileModelSource
- All Implemented Interfaces:
- Source,- ModelSource,- ModelSource2,- ModelSource3
Wraps an ordinary 
File as a model source.- 
Constructor SummaryConstructorsConstructorDescriptionFileModelSource(File pomFile) Creates a new model source backed by the specified file.
- 
Method SummaryModifier and TypeMethodDescriptionbooleanReturns location of the POM, nevernull.Deprecated.getRelatedSource(ModelLocator locator, String relPath) Returns model source identified by a path relative to this model source POM.inthashCode()Methods inherited from class org.apache.maven.building.FileSourcegetFile, getInputStream, getLocation, toStringMethods inherited from class java.lang.Objectclone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.apache.maven.model.building.ModelSource3getRelatedSourceMethods inherited from interface org.apache.maven.building.SourcegetInputStream, getLocation
- 
Constructor Details- 
FileModelSourceCreates a new model source backed by the specified file.- Parameters:
- pomFile- The POM file, must not be- null.
 
 
- 
- 
Method Details- 
getPomFileDeprecated.instead useFileSource.getFile()- Returns:
- the file of this source
 
- 
getRelatedSourceDescription copied from interface:ModelSource3Returns model source identified by a path relative to this model source POM. Implementation MUST acceptrelPathparameter values that- use either / or \ file path separator
- have .. parent directory references
- point either at file or directory
 ModelLocatorwill be used to find the POM file, else if no locator is provided, a file named 'pom.xml' needs to be used by the requested model source.- Specified by:
- getRelatedSourcein interface- ModelSource3
- Parameters:
- locator- locator used to locate the pom file
- relPath- path of the requested model source relative to this model source POM
- Returns:
- related model source or nullif no such model source
 
- 
getLocationURIDescription copied from interface:ModelSource2Returns location of the POM, nevernull.- Specified by:
- getLocationURIin interface- ModelSource2
 
- 
equals- Overrides:
- equalsin class- FileSource
 
- 
hashCodepublic int hashCode()- Overrides:
- hashCodein class- FileSource
 
 
- 
FileSource.getFile()