computeEnvelopeInternal method

Envelope computeEnvelopeInternal()
override

Returns the minimum and maximum x and y values in this Geometry , or a null Envelope if this Geometry is empty. Unlike getEnvelopeInternal, this method calculates the Envelope each time it is called; getEnvelopeInternal caches the result of this method.

@return this Geometrys bounding box; if the Geometry is empty, Envelope#isNull will return true

Implementation

Envelope computeEnvelopeInternal() {
  Envelope envelope = new Envelope.empty();
  for (int i = 0; i < geometries.length; i++) {
    envelope.expandToIncludeEnvelope(geometries[i].getEnvelopeInternal());
  }
  return envelope;
}