|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.reades.mapthing.Generic
com.reades.mapthing.Lines
public class Lines
Creates lines from a MultiLine shape file in ArcGIS or (still looking for test cases) x/y pairs in a CSV file.
Issues to be tested/implemented:
Field Summary | |
---|---|
boolean |
DEBUG
|
Constructor Summary | |
---|---|
Lines(BoundingBox b,
Instantiate the GeoLine object with a BoundingBox and Feature Collection object. |
|
Lines(BoundingBox b,
String r)
Instantiate the GeoLine object with a BoundingBox and String. |
Method Summary | |
---|---|
ArrayList<Coordinate[]> |
getCoordinates()
Returns an ArrayList |
ArrayList<Node[]> |
getCoordinates(PApplet a)
Return an ArrayList |
void |
project(PApplet a)
Draws all of the lines contained in a Lines object loaded from a file. |
void |
project(PApplet a,
PGraphics p)
Draws all of the lines contained in a Lines object loaded from a file into a PGraphics object so that you can use it as a buffer. |
void |
projectValues(PApplet a,
float min,
float max)
Apply a color scale to the the polygons so that it is possible to represent the values in a useful way. |
void |
reverse()
Reverses the order of the points in a polygon. |
void |
transformCoordinates(PApplet a)
You don't normally need to call this directly, as it will be done for you when you ask for the file to be projected in the Applet. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public boolean DEBUG
Constructor Detail |
---|
public Lines(BoundingBox b, String r)
b
- the bounding box of the default viewr
- a String that allows us to determine the type of resource to openpublic Lines(BoundingBox b,f)
b
- the bounding box of the default viewportf
- a reference to FeatureCollection of SimpleFeature objectsMethod Detail |
---|
public void transformCoordinates(PApplet a)
a
- a Processing PApplet objectpublic ArrayList<Node[]> getCoordinates(PApplet a)
public ArrayList<Coordinate[]> getCoordinates()
public void project(PApplet a)
object.project(this)
.
a
- a Processing PApplet objectpublic void projectValues(PApplet a, float min, float max)
a
- a Processing PApplet objectmin
- the minimum value of the value field (I will try to make this automatic in later releases)max
- the maximum value of the value field (I will try to make this automatic in later releases)public void project(PApplet a, PGraphics p)
Draws all of the lines contained in a Lines object loaded from a file into a PGraphics object so that you can use it as a buffer.
a
- a Processing PApplet objectp
- a Processing PGraphicspublic void reverse()
Reverses the order of the points in a polygon. Note that this will only do something if you have already called transformCoordinates or project once (since it only works on the points that have been mapped into the Processing sketch.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |