public class Resource extends Object
| Constructor and Description |
|---|
Resource()
Empty constructor.
|
| Modifier and Type | Method and Description |
|---|---|
static Resource |
create(String uri)
Creates a resource and set the correct
ResourceType based on uri extension. |
static Resource |
create(String uri,
ResourceType type)
Factory method for Resource creation.
|
boolean |
equals(Object obj) |
ResourceType |
getType() |
String |
getUri() |
int |
hashCode() |
boolean |
isMinimize() |
void |
setMinimize(boolean minimize) |
void |
setType(ResourceType type) |
void |
setUri(String uri) |
String |
toString() |
public static Resource create(String uri, ResourceType type)
Resource object.public static Resource create(String uri)
ResourceType based on uri extension. If resourceType cannot be
identified an exception is thrown.uri - of the resource to create.public void setType(ResourceType type)
type - the type to setpublic void setUri(String uri)
uri - the uri to setpublic ResourceType getType()
public String getUri()
public boolean isMinimize()
public void setMinimize(boolean minimize)
minimize - the minimize to setpublic String toString()
toString in class ObjectObject.toString()Copyright © 2008-2013. All Rights Reserved.