@Immutable @Loggable(value=1) public static final class Content.Smart extends Object implements Content
Content.Smart| Modifier and Type | Method and Description |
|---|---|
int |
compareTo(Content cont) |
String |
content()
Get its encoded content.
|
byte[] |
decoded()
Get its decoded content.
|
URL |
gitUrl()
Get its GIT URL.
|
URL |
htmlUrl()
Get its HTML URL.
|
javax.json.JsonObject |
json()
Describe it in a JSON object.
|
String |
name()
Get its name.
|
void |
patch(javax.json.JsonObject json)
Patch using this JSON object.
|
String |
path()
Get its path name.
|
InputStream |
raw()
Get the raw contents.
|
Repo |
repo()
Repository we're in.
|
String |
sha()
Get its sha hash.
|
int |
size()
Get its size.
|
String |
type()
Get its type.
|
URL |
url()
Get its URL.
|
public Smart(Content cont)
cont - Contentpublic String name() throws IOException
IOException - If there is any I/O problempublic String type() throws IOException
IOException - If there is any I/O problempublic int size()
throws IOException
IOException - If it failspublic String sha() throws IOException
IOException - If there is any I/O problempublic URL url() throws IOException
IOException - If there is any I/O problempublic URL htmlUrl() throws IOException
IOException - If there is any I/O problempublic URL gitUrl() throws IOException
IOException - If there is any I/O problempublic String content() throws IOException
IOException - If there is any I/O problempublic byte[] decoded()
throws IOException
IOException - If there is any I/O problempublic int compareTo(Content cont)
compareTo in interface Comparable<Content>public void patch(javax.json.JsonObject json)
throws IOException
JsonPatchablepatch in interface JsonPatchablejson - JSON objectIOException - If there is any I/O problempublic javax.json.JsonObject json()
throws IOException
JsonReadablejson in interface JsonReadableIOException - If there is any I/O problempublic InputStream raw() throws IOException
Contentraw in interface ContentIOException - If an IO error occursCopyright © 2012–2018 jcabi.com. All rights reserved.