Package jetbrains.mps.extapi.persistence
Interface SourceRoot
- 
- All Known Implementing Classes:
 DefaultSourceRoot
public interface SourceRootA unit to build up the file model root. Has one file path -- the root of the model sources. Many models may lie within oneSourceRoot[Typically it is a directory which contains models] AP Currently it does not store a reference to the enclosingModelRootand probably it is for the best.- Since:
 - 3.5
 
 
- 
- 
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description IFilegetAbsolutePath()Now it is hard to resolve a path againstFileBasedModelRoot.getContentDirectory()because we still do not have a proper API.StringgetPath()Returns a path to the source root it is linked to. 
 - 
 
- 
- 
Method Detail
- 
getPath
@NotNull String getPath()
Returns a path to the source root it is linked to. Path can be absolute or relative to theFileBasedModelRoot.getContentDirectory()Currently the type isStringsince we do not have relative path classes in the API. [But soon enough it will be replaced FIXME AP] Until then the contract is to return a system-independent (UNIX separators) path.- Returns:
 - a system-independent (UNIX separators) path where the models sources lie
 
 
- 
getAbsolutePath
@NotNull IFile getAbsolutePath()
Now it is hard to resolve a path againstFileBasedModelRoot.getContentDirectory()because we still do not have a proper API. Temporarily this method will replace the api. Afterwards there will be onlygetPath()method which will return some "Path" entity 
 - 
 
 -