|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.overlord.sramp.atom.SrampAtomUtils
public final class SrampAtomUtils
Some useful static utils for users of the s-ramp client.
| Method Summary | ||
|---|---|---|
static ArtifactType |
getArtifactType(org.jboss.resteasy.plugins.providers.atom.Entry entry)
Figures out the S-RAMP artifact type for the given Entry. |
|
protected static ArtifactType |
getArtifactTypeFromEntry(org.jboss.resteasy.plugins.providers.atom.Entry entry)
Figures out the S-RAMP artifact type for the given Entry. |
|
static
|
unwrap(org.jboss.resteasy.plugins.providers.atom.Entry entry,
Class<T> clazz)
Unwrap some other jaxb object from its Atom Entry wrapper. |
|
static BaseArtifactType |
unwrapSrampArtifact(ArtifactType artifactType,
Artifact artifact)
Unwraps the specific BaseArtifactType from the S-RAMP Artifact wrapper
element. |
|
static BaseArtifactType |
unwrapSrampArtifact(ArtifactType artifactType,
org.jboss.resteasy.plugins.providers.atom.Entry entry)
Unwraps a specific BaseArtifactType from the Atom Entry containing it. |
|
static BaseArtifactType |
unwrapSrampArtifact(org.jboss.resteasy.plugins.providers.atom.Entry entry)
Unwraps a specific BaseArtifactType from the Atom Entry containing it. |
|
static org.jboss.resteasy.plugins.providers.atom.Entry |
wrapSrampArtifact(BaseArtifactType artifact)
Wraps the given s-ramp artifact in an Atom Entry. |
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static BaseArtifactType unwrapSrampArtifact(ArtifactType artifactType,
Artifact artifact)
BaseArtifactType from the S-RAMP Artifact wrapper
element. This method requires the artifact's type.
artifactType - the s-ramp artifact typeartifact - the s-ramp wrapper Artifact
BaseArtifactTypepublic static BaseArtifactType unwrapSrampArtifact(org.jboss.resteasy.plugins.providers.atom.Entry entry)
BaseArtifactType from the Atom Entry containing it. This
method grabs the Artifact child from the Atom Entry and then unwraps the
BaseArtifactType from that.
entry - an Atom Entry
BaseArtifactType
public static BaseArtifactType unwrapSrampArtifact(ArtifactType artifactType,
org.jboss.resteasy.plugins.providers.atom.Entry entry)
BaseArtifactType from the Atom Entry containing it. This
method grabs the Artifact child from the Atom Entry and then unwraps the
BaseArtifactType from that.
artifactType - the s-ramp artifact typeentry - an Atom Entry
BaseArtifactType
public static org.jboss.resteasy.plugins.providers.atom.Entry wrapSrampArtifact(BaseArtifactType artifact)
throws URISyntaxException,
IllegalArgumentException,
IllegalAccessException,
InvocationTargetException,
SecurityException,
NoSuchMethodException
Entry.
artifact -
URISyntaxException
InvocationTargetException
IllegalAccessException
IllegalArgumentException
NoSuchMethodException
SecurityExceptionpublic static ArtifactType getArtifactType(org.jboss.resteasy.plugins.providers.atom.Entry entry)
Entry.
entry - protected static ArtifactType getArtifactTypeFromEntry(org.jboss.resteasy.plugins.providers.atom.Entry entry)
Entry. There are a number of
ways we can do this. We'll try them all:
1) check the 'self' link, parsing it for the type and model information
2) check the Atom Category - there should be one for the artifact type
3) unwrap the Entry's Artifact and get the artifactType value (xml attribute)
entry -
public static <T> T unwrap(org.jboss.resteasy.plugins.providers.atom.Entry entry,
Class<T> clazz)
throws JAXBException
entry - clazz -
JAXBException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||