com.backendless.persistence.BackendlessGeometryWriter Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of java-sdk-common Show documentation
Show all versions of java-sdk-common Show documentation
Provides access to Backendless API
The newest version!
package com.backendless.persistence;
import weborb.writer.IProtocolFormatter;
import weborb.writer.ITypeWriter;
import weborb.writer.MessageWriter;
import java.io.IOException;
public class BackendlessGeometryWriter implements ITypeWriter
{
@Override
public void write( Object o, IProtocolFormatter iProtocolFormatter ) throws IOException
{
Geometry geometry = (Geometry) o;
GeometryDTO geometryDTO = new GeometryDTO(geometry.getClass().getName(), geometry.getSRS().getSRSId(), geometry.asGeoJSON());
MessageWriter.writeObject(geometryDTO, iProtocolFormatter);
}
@Override
public boolean isReferenceableType()
{
return false;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy