Class Geometry2dApi

java.lang.Object
nl.bimbase.bimworks.client.apis.SubApi
nl.bimbase.bimworks.client.apis.Geometry2dApi

public class Geometry2dApi extends SubApi
2D geometry: what the 2D viewer downloads, floor plan SVG export, and footprints.
  • Constructor Details

  • Method Details

    • downloadGeometry2D

      public long downloadGeometry2D(UUID versionUuid, String query, LongConsumer chunkListener) throws BimWorksException
      Download the 2D viewer geometry of a model, as the 2D viewer does: the payload arrives as binary pushes (settings, base translation, bounding box, geometry chunks).
      Parameters:
      query - the BQL selecting the products to draw
      chunkListener - receives each chunk's size, may be null
      Returns:
      the number of bytes received
      Throws:
      BimWorksException
    • exportSvg

      public InputStream exportSvg(UUID versionUuid) throws BimWorksException
      Floor plan of the first building storey as SVG. The caller closes the stream.
      Throws:
      BimWorksException
    • getFootprint

      @Deprecated public com.fasterxml.jackson.databind.node.ObjectNode getFootprint(UUID versionUuid, Geometry2dApi.FootprintType type) throws BimWorksException
      Deprecated.
      Query the shape with BQL instead (client.bim.query), over any set of objects and with its holes: GET PROJECTION().wkt("EPSG:4326"), PROJECTION(MINIMUM_RECTANGLE) for the rectangle, SLICE(1200 mm) for a cut. GetGeoReference answers the placed zero_point and bounds_centre.
      {wkt, anchor_point, zero_point, geo_reference} of the model's footprint.
      Throws:
      BimWorksException