Tabnine Logo
mil.nga.sf.util
Code IndexAdd Tabnine to your IDE (free)

How to use mil.nga.sf.util

Best Java code snippets using mil.nga.sf.util (Showing top 20 results out of 315)

origin: mil.nga/sf

/**
 * Get the mathematical centroid for this Geometry as a Point
 * 
 * @return centroid point
 */
public Point getCentroid() {
  return GeometryUtils.getCentroid(this);
}
origin: mil.nga/sf

/**
 * Read a byte
 * 
 * @return byte
 */
public byte readByte() {
  verifyRemainingBytes(1);
  byte value = bytes[nextByte];
  nextByte++;
  return value;
}
origin: mil.nga/sf

/**
 * Get the minimum bounding box for this Geometry
 * 
 * @return geometry envelope
 */
public GeometryEnvelope getEnvelope() {
  return GeometryEnvelopeBuilder.buildEnvelope(this);
}
origin: mil.nga/sf

/**
 * Constructor
 * 
 * @param rings
 *            list of rings
 */
public Triangle(List<LineString> rings) {
  this(GeometryUtils.hasZ(rings), GeometryUtils.hasM(rings));
  setRings(rings);
}
origin: mil.nga/sf

/**
 * Read an unsigned integer
 * 
 * @return unsigned integer
 */
public long readUnsignedInt() {
  int intValue = readInt();
  long value = intValue & 0xffffffffL;
  return value;
}
origin: mil.nga/sf

/**
 * Verify with the remaining bytes that there are enough remaining to read
 * the provided amount
 * 
 * @param bytesToRead
 *            number of bytes to read
 */
private void verifyRemainingBytes(int bytesToRead) {
  if (nextByte + bytesToRead > bytes.length) {
    throw new SFException(
        "No more remaining bytes to read. Total Bytes: "
            + bytes.length + ", Bytes already read: "
            + nextByte + ", Attempted to read: " + bytesToRead);
  }
}
origin: mil.nga/sf

/**
 * Check if the point is on the polygon ring edge
 * 
 * @param point
 *            point
 * @param ring
 *            polygon ring
 * @return true if on the polygon edge
 * @since 1.0.5
 */
public static boolean pointOnPolygonEdge(Point point, LineString ring) {
  return pointOnPolygonEdge(point, ring, DEFAULT_EPSILON);
}
origin: mil.nga/sf

/**
 * Check if the point is in the polygon
 * 
 * @param point
 *            point
 * @param polygon
 *            polygon
 * @return true if in the polygon
 * @since 1.0.5
 */
public static boolean pointInPolygon(Point point, Polygon polygon) {
  return pointInPolygon(point, polygon, DEFAULT_EPSILON);
}
origin: mil.nga/sf

/**
 * Check if the point is on the line represented by the points
 * 
 * @param point
 *            point
 * @param points
 *            line points
 * @return true if on the line
 * @since 1.0.5
 */
public static boolean pointOnLine(Point point, List<Point> points) {
  return pointOnLine(point, points, DEFAULT_EPSILON);
}
origin: mil.nga/sf

/**
 * Check if the point is on the path between point 1 and point 2
 * 
 * @param point
 *            point
 * @param point1
 *            path point 1
 * @param point2
 *            path point 2
 * @return true if on the path
 * @since 1.0.5
 */
public static boolean pointOnPath(Point point, Point point1, Point point2) {
  return pointOnPath(point, point1, point2, DEFAULT_EPSILON);
}
origin: mil.nga/sf

/**
 * Get the inherent dimension (0, 1, or 2) for this Geometry
 * 
 * @return dimension
 */
public int getDimension() {
  return GeometryUtils.getDimension(this);
}
origin: mil.nga/sf

/**
 * Constructor
 * 
 * @param points
 *            list of points
 */
public CircularString(List<Point> points) {
  this(GeometryUtils.hasZ(points), GeometryUtils.hasM(points));
  setPoints(points);
}
origin: mil.nga/sf

/**
 * Check if the point is on the polygon edge
 * 
 * @param point
 *            point
 * @param polygon
 *            polygon
 * @return true if on the polygon edge
 * @since 1.0.5
 */
public static boolean pointOnPolygonEdge(Point point, Polygon polygon) {
  return pointOnPolygonEdge(point, polygon, DEFAULT_EPSILON);
}
origin: mil.nga/sf

/**
 * Check if the point is in the polygon points
 * 
 * @param point
 *            point
 * @param points
 *            polygon points
 * @return true if in the polygon
 * @since 1.0.5
 */
public static boolean pointInPolygon(Point point, List<Point> points) {
  return pointInPolygon(point, points, DEFAULT_EPSILON);
}
origin: mil.nga/sf

/**
 * Check if the point is on the line
 * 
 * @param point
 *            point
 * @param line
 *            line
 * @return true if on the line
 * @since 1.0.5
 */
public static boolean pointOnLine(Point point, LineString line) {
  return pointOnLine(point, line, DEFAULT_EPSILON);
}
origin: mil.nga/sf

/**
 * Check if the point is on the line represented by the points
 * 
 * @param point
 *            point
 * @param points
 *            line points
 * @param epsilon
 *            epsilon line tolerance
 * @return true if on the line
 * @since 1.0.5
 */
public static boolean pointOnLine(Point point, List<Point> points,
    double epsilon) {
  return pointOnPath(point, points, epsilon, false);
}
origin: mil.nga/sf

/**
 * Constructor
 * 
 * @param points
 *            list of points
 */
public MultiPoint(List<Point> points) {
  this(GeometryUtils.hasZ(points), GeometryUtils.hasM(points));
  setPoints(points);
}
origin: mil.nga/sf

/**
 * Check if the point is on the polygon ring edge points
 * 
 * @param point
 *            point
 * @param points
 *            polygon points
 * @return true if on the polygon edge
 * @since 1.0.5
 */
public static boolean pointOnPolygonEdge(Point point, List<Point> points) {
  return pointOnPolygonEdge(point, points, DEFAULT_EPSILON);
}
origin: mil.nga/sf

/**
 * Check if the point is in the polygon ring
 * 
 * @param point
 *            point
 * @param ring
 *            polygon ring
 * @return true if in the polygon
 * @since 1.0.5
 */
public static boolean pointInPolygon(Point point, LineString ring) {
  return pointInPolygon(point, ring, DEFAULT_EPSILON);
}
origin: mil.nga/sf

/**
 * Constructor
 * 
 * @param lineStrings
 *            list of line strings
 */
public CompoundCurve(List<LineString> lineStrings) {
  this(GeometryUtils.hasZ(lineStrings), GeometryUtils.hasM(lineStrings));
  setLineStrings(lineStrings);
}
mil.nga.sf.util

Most used classes

  • ByteReader
    Read through a byte array
  • GeometryEnvelopeBuilder
    Builds an envelope from a Geometry
  • GeometryUtils
    Utilities for Geometry objects
  • SFException
    Simple Features exception
  • ByteWriter
    Write a byte array
  • CentroidCurve,
  • CentroidPoint,
  • CentroidSurface,
  • Event,
  • EventQueue,
  • Segment,
  • ShamosHoey,
  • SweepLine$SegmentComparator,
  • SweepLine
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now