public class Resource extends Object
Class.getResource(String).| Modifier and Type | Method and Description |
|---|---|
byte[] |
asByteArray() |
File |
asFile() |
InputStream |
asInputStream() |
Reader |
asReader() |
String |
asText() |
String |
getName()
Gets just the file name portion without any paths, like "foo.txt"
|
public final URL url
public Resource(URL url)
public String getName()
public InputStream asInputStream()
public Reader asReader()
public String asText()
public byte[] asByteArray()
throws IOException
IOExceptionpublic File asFile()
Copyright © 2004–2017. All rights reserved.