ing
This commit is contained in:
parent
de27bebe66
commit
ca7b0465a9
2
pom.xml
2
pom.xml
|
@ -13,7 +13,7 @@
|
||||||
<groupId>com.loafle.overflow</groupId>
|
<groupId>com.loafle.overflow</groupId>
|
||||||
<artifactId>commons-java</artifactId>
|
<artifactId>commons-java</artifactId>
|
||||||
<packaging>jar</packaging>
|
<packaging>jar</packaging>
|
||||||
<version>1.0.84-SNAPSHOT</version>
|
<version>1.0.85-SNAPSHOT</version>
|
||||||
<name>com.loafle.overflow.commons-java</name>
|
<name>com.loafle.overflow.commons-java</name>
|
||||||
|
|
||||||
<properties>
|
<properties>
|
||||||
|
|
|
@ -26,13 +26,11 @@ public class InfraHostIPsSerializer extends StdSerializer<List<InfraHostIP>> {
|
||||||
@Override
|
@Override
|
||||||
public void serialize(List<InfraHostIP> infraHostIPs, JsonGenerator gen, SerializerProvider provider)
|
public void serialize(List<InfraHostIP> infraHostIPs, JsonGenerator gen, SerializerProvider provider)
|
||||||
throws IOException {
|
throws IOException {
|
||||||
if (null == infraHostIPs) {
|
if (null != infraHostIPs) {
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
for (InfraHostIP infraHostIP : infraHostIPs) {
|
for (InfraHostIP infraHostIP : infraHostIPs) {
|
||||||
infraHostIP.setInfraHost(null);
|
infraHostIP.setInfraHost(null);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
gen.writeObject(infraHostIPs);
|
gen.writeObject(infraHostIPs);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user