Package org.commonjava.maven.ext.io
Class FileIO
- java.lang.Object
-
- org.commonjava.maven.ext.io.FileIO
-
@Named @Singleton public class FileIO extends Object
Class to resolve Files from alternate locations
-
-
Constructor Summary
Constructors Constructor Description FileIO(GalleyInfrastructure infra)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static org.commonjava.maven.ext.common.util.LineSeparator
determineEOL(File file)
File
resolveURL(String reference)
Read the raw file from a given URL.
-
-
-
Constructor Detail
-
FileIO
@Inject public FileIO(@Named("galley") GalleyInfrastructure infra)
-
-
Method Detail
-
resolveURL
public File resolveURL(String reference) throws IOException
Read the raw file from a given URL. Useful if we need to read a remote file.- Parameters:
reference
- the URL to read.- Returns:
- the file for the URL
- Throws:
IOException
- if an error occurs.
-
determineEOL
public static org.commonjava.maven.ext.common.util.LineSeparator determineEOL(File file) throws org.commonjava.maven.ext.common.ManipulationException
- Throws:
org.commonjava.maven.ext.common.ManipulationException
-
-