Setting target version of maven compiler plugin to 1.7

revert-70aa11f8
prabathabey 10 years ago
parent 2dc1c7341a
commit 85aec417e5

@ -55,17 +55,11 @@ public class FaultMessageBodyWriter implements MessageBodyWriter<FaultResponse>
public void writeTo(FaultResponse faultResponse, Class<?> aClass, Type type, Annotation[] annotations, public void writeTo(FaultResponse faultResponse, Class<?> aClass, Type type, Annotation[] annotations,
MediaType mediaType, MultivaluedMap<String, Object> stringObjectMultivaluedMap, MediaType mediaType, MultivaluedMap<String, Object> stringObjectMultivaluedMap,
OutputStream outputStream) throws IOException, WebApplicationException { OutputStream outputStream) throws IOException, WebApplicationException {
OutputStreamWriter writer = null; try (OutputStreamWriter writer = new OutputStreamWriter(outputStream, UTF_8)) {
try {
writer = new OutputStreamWriter(outputStream, UTF_8);
JsonObject response = new JsonObject(); JsonObject response = new JsonObject();
response.addProperty("error", faultResponse.getCode().getValue()); response.addProperty("error", faultResponse.getCode().getValue());
response.addProperty("error_description", faultResponse.getDescription()); response.addProperty("error_description", faultResponse.getDescription());
getGson().toJson(response, type, writer); getGson().toJson(response, type, writer);
} finally {
if (writer != null) {
writer.close();
}
} }
} }

@ -945,16 +945,16 @@
</execution> </execution>
</executions> </executions>
</plugin> </plugin>
<!--<plugin>--> <plugin>
<!--<groupId>org.apache.maven.plugins</groupId>--> <groupId>org.apache.maven.plugins</groupId>
<!--<artifactId>maven-compiler-plugin</artifactId>--> <artifactId>maven-compiler-plugin</artifactId>
<!--<version>2.3.1</version>--> <version>2.3.1</version>
<!--<configuration>--> <configuration>
<!--<encoding>UTF-8</encoding>--> <encoding>UTF-8</encoding>
<!--<source>1.6</source>--> <source>1.7</source>
<!--<target>1.6</target>--> <target>1.7</target>
<!--</configuration>--> </configuration>
<!--</plugin>--> </plugin>
<plugin> <plugin>
<groupId>org.apache.maven.plugins</groupId> <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-release-plugin</artifactId> <artifactId>maven-release-plugin</artifactId>

Loading…
Cancel
Save