Package org.nd4j.common.io
Class AbstractFileResolvingResource
- java.lang.Object
-
- org.nd4j.common.io.AbstractResource
-
- org.nd4j.common.io.AbstractFileResolvingResource
-
- All Implemented Interfaces:
InputStreamSource,Resource
- Direct Known Subclasses:
ClassPathResource
public abstract class AbstractFileResolvingResource extends AbstractResource
-
-
Constructor Summary
Constructors Constructor Description AbstractFileResolvingResource()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description longcontentLength()booleanexists()Whether the resource exists on the classpathFilegetFile()protected FilegetFile(URI uri)protected FilegetFileForLastModifiedCheck()booleanisReadable()longlastModified()-
Methods inherited from class org.nd4j.common.io.AbstractResource
createRelative, equals, getFilename, getURI, getURL, hashCode, isOpen, toString
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.nd4j.common.io.InputStreamSource
getInputStream
-
Methods inherited from interface org.nd4j.common.io.Resource
getDescription
-
-
-
-
Method Detail
-
getFile
public File getFile() throws IOException
- Specified by:
getFilein interfaceResource- Overrides:
getFilein classAbstractResource- Returns:
- Throws:
IOException
-
getFileForLastModifiedCheck
protected File getFileForLastModifiedCheck() throws IOException
- Overrides:
getFileForLastModifiedCheckin classAbstractResource- Throws:
IOException
-
getFile
protected File getFile(URI uri) throws IOException
- Throws:
IOException
-
exists
public boolean exists()
Description copied from interface:ResourceWhether the resource exists on the classpath- Specified by:
existsin interfaceResource- Overrides:
existsin classAbstractResource- Returns:
-
isReadable
public boolean isReadable()
- Specified by:
isReadablein interfaceResource- Overrides:
isReadablein classAbstractResource- Returns:
-
contentLength
public long contentLength() throws IOException- Specified by:
contentLengthin interfaceResource- Overrides:
contentLengthin classAbstractResource- Returns:
- Throws:
IOException
-
lastModified
public long lastModified() throws IOException- Specified by:
lastModifiedin interfaceResource- Overrides:
lastModifiedin classAbstractResource- Returns:
- Throws:
IOException
-
-