code: public static Geometry multiplyZ(Geometry geometry, double z) throws SQLException {
          if(geometry == null){
              return null;
          }
          geometry.apply(new MultiplyZCoordinateSequenceFilter(z));
          return geometry;
      }
docs: Multiply the z values of the geometry by another double value. NaN values
  are not updated.
  
  @param geometry
  @param z
  @return
  @throws java.sql.SQLException