Atavism Version 2018.1AGIS API

atavism.server.objects
Class Boundary

java.lang.Object
  extended by atavism.server.objects.Boundary
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable

public class Boundary
extends java.lang.Object
implements java.lang.Cloneable, java.io.Serializable

although we use a 3d point, this boundary is a 2d boundary which only looks at the X,Z values of the point

See Also:
Serialized Form

Field Summary
protected  Geometry boundingBox
           
 
Constructor Summary
Boundary()
           
Boundary(java.util.List<Point> points)
           
Boundary(java.lang.String name)
           
 
Method Summary
 void addPoint(Point p)
           
 java.lang.Object clone()
           
 boolean contains(Point p)
          returns if the point is contained within this 2d boundary pick a point outside of the boundary, create a line segment from the point in question, to the point outside the line. count how many times it crosses line segments of the boundary. if even, its not inside the boundary
 Geometry getBoundingBox()
           
static Boundary getMaxBoundary()
           
 java.lang.String getName()
           
 java.util.List<Point> getPoints()
           
 void setName(java.lang.String name)
           
 void setPoints(java.util.List<Point> points)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

boundingBox

protected Geometry boundingBox
Constructor Detail

Boundary

public Boundary()

Boundary

public Boundary(java.lang.String name)

Boundary

public Boundary(java.util.List<Point> points)
Method Detail

setName

public void setName(java.lang.String name)

getName

public java.lang.String getName()

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

clone

public java.lang.Object clone()
Overrides:
clone in class java.lang.Object

setPoints

public void setPoints(java.util.List<Point> points)

getPoints

public java.util.List<Point> getPoints()

addPoint

public void addPoint(Point p)

getBoundingBox

public Geometry getBoundingBox()

contains

public boolean contains(Point p)
returns if the point is contained within this 2d boundary pick a point outside of the boundary, create a line segment from the point in question, to the point outside the line. count how many times it crosses line segments of the boundary. if even, its not inside the boundary


getMaxBoundary

public static Boundary getMaxBoundary()


Copyright © 2018 Dragonsan Studios Sp. z o.o.