Package org.hypermedea.ct
Class RepresentationHandlers
java.lang.Object
org.hypermedea.ct.RepresentationHandlers
Factory class to (de)serialize resource representations in (from) known Content-Types.
-
Method Summary
Modifier and TypeMethodDescriptionstatic Collection<jason.asSyntax.Literal>
deserialize
(InputStream representation, String resourceURI, String contentType) static String
getDefaultContentType
(Collection<jason.asSyntax.Literal> terms) static void
serialize
(Collection<jason.asSyntax.Literal> terms, OutputStream out, String resourceURI)
-
Method Details
-
serialize
public static void serialize(Collection<jason.asSyntax.Literal> terms, OutputStream out, String resourceURI) throws UnsupportedRepresentationException, IOException -
deserialize
public static Collection<jason.asSyntax.Literal> deserialize(InputStream representation, String resourceURI, String contentType) throws UnsupportedRepresentationException, IOException -
getDefaultContentType
public static String getDefaultContentType(Collection<jason.asSyntax.Literal> terms) throws UnsupportedRepresentationException
-