aboutsummaryrefslogtreecommitdiff
path: root/src/main
diff options
context:
space:
mode:
authorChristof Rabensteiner <christof.rabensteiner@iaik.tugraz.at>2019-05-13 09:28:52 +0200
committerChristof Rabensteiner <christof.rabensteiner@iaik.tugraz.at>2019-05-13 09:28:52 +0200
commit840474fdfcee245f49dfee08b67f6f9ba6d3de1f (patch)
treeddbd71b1b21e517873539808b79b23b166ae43a8 /src/main
parent9ecfae00dd37592b1e5fdeebb2ab0b8e9129b873 (diff)
downloadmoa-zs-840474fdfcee245f49dfee08b67f6f9ba6d3de1f.tar.gz
moa-zs-840474fdfcee245f49dfee08b67f6f9ba6d3de1f.tar.bz2
moa-zs-840474fdfcee245f49dfee08b67f6f9ba6d3de1f.zip
Refactor Marshaller
- Rename jaxbmarshaller field to prevent confusion with class name.
Diffstat (limited to 'src/main')
-rw-r--r--src/main/java/at/gv/egiz/moazs/scheme/Marshaller.java8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/main/java/at/gv/egiz/moazs/scheme/Marshaller.java b/src/main/java/at/gv/egiz/moazs/scheme/Marshaller.java
index 2dbb6a0..3c82419 100644
--- a/src/main/java/at/gv/egiz/moazs/scheme/Marshaller.java
+++ b/src/main/java/at/gv/egiz/moazs/scheme/Marshaller.java
@@ -14,20 +14,20 @@ import java.io.StringWriter;
*/
public class Marshaller {
- private final Jaxb2Marshaller marshaller;
+ private final Jaxb2Marshaller jaxbMarshaller;
public Marshaller(Jaxb2Marshaller marshaller) {
- this.marshaller = marshaller;
+ this.jaxbMarshaller = marshaller;
}
public <T> String marshallXml(final T obj) {
StringWriter sw = new StringWriter();
Result result = new StreamResult(sw);
- marshaller.marshal(obj, result);
+ jaxbMarshaller.marshal(obj, result);
return sw.toString();
}
public <T> T unmarshallXml(final InputStream xml) {
- return (T) marshaller.unmarshal(new StreamSource(xml));
+ return (T) jaxbMarshaller.unmarshal(new StreamSource(xml));
}
}