类 FileLocation
- java.lang.Object
-
- org.apache.maven.shared.io.location.FileLocation
-
- 所有已实现的接口:
Location
- 直接已知子类:
ArtifactLocation
,URLLocation
public class FileLocation extends java.lang.Object implements Location
file location implementation.
-
-
构造器概要
构造器 限定符 构造器 说明 FileLocation(java.io.File file, java.lang.String specification)
protected
FileLocation(java.lang.String specification)
-
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 void
close()
Close the location.java.io.File
getFile()
java.io.InputStream
getInputStream()
java.lang.String
getSpecification()
protected void
initFile()
initialize file.void
open()
open the location.int
read(byte[] buffer)
int
read(java.nio.ByteBuffer buffer)
protected void
setFile(java.io.File file)
protected java.io.File
unsafeGetFile()
-
-
-
方法详细资料
-
getFile
public java.io.File getFile() throws java.io.IOException
-
unsafeGetFile
protected java.io.File unsafeGetFile()
- 返回:
File
-
initFile
protected void initFile() throws java.io.IOException
initialize file.- 抛出:
java.io.IOException
- in case error.
-
setFile
protected void setFile(java.io.File file)
- 参数:
file
-File
-
getSpecification
public java.lang.String getSpecification()
- 指定者:
getSpecification
在接口中Location
- 返回:
- spec.
-
open
public void open() throws java.io.IOException
open the location.
-
read
public int read(java.nio.ByteBuffer buffer) throws java.io.IOException
-
read
public int read(byte[] buffer) throws java.io.IOException
-
getInputStream
public java.io.InputStream getInputStream() throws java.io.IOException
- 指定者:
getInputStream
在接口中Location
- 返回:
- the resulting input stream.
- 抛出:
java.io.IOException
- in case of an error.
-
-