|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectno.uio.edd.utils.geoutils.GeoFeature
no.uio.edd.model.geo.map.GeoPlace
public class GeoPlace
A class used to store a place in a map model. The myId is the same as the RDF url for the node it was based on.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class no.uio.edd.utils.geoutils.GeoFeature |
---|
GeoFeature.possibleForms |
Field Summary | |
---|---|
(package private) int |
relationshipCounter
|
Fields inherited from class no.uio.edd.utils.geoutils.GeoFeature |
---|
coordSyst, coordSystNumeric, KOORD_NAME_GENERALSTABEN, KOORD_NAME_REKTANGEL, MAP_IDENT_GENERALSTABEN, MAP_IDENT_REKTANGEL, myId, OFFSET_CHRA, OFFSET_STHLM |
Constructor Summary | |
---|---|
GeoPlace(java.lang.String id,
GeoMap inGeoMap)
|
Method Summary | |
---|---|
java.lang.String |
addAnnotation(java.lang.String newAnn)
Add to the list of annotation. |
GeoEvent |
addEvent(java.lang.String id)
Add a new event to this place. |
GeoRelationship |
addGeoRelationshipToMe(GeoRelationship newRel)
Adds a new relationship for which I am the target. |
void |
addType(java.lang.String type)
Adds another type to my list of types. |
java.lang.String |
asCoordList()
|
java.lang.String |
asGML()
The GML fragment returned by this method should contain everything from the level of the specific geometry, that is, from gml:Point, gml:Polygon, etc. |
int |
countRelationshipsWithoutSpec()
That is, relationships where neither direction, distance, isPartOf nor isBetween is set. |
boolean |
coveredByMe(GeoPlace gp)
|
boolean |
doIHaveParts()
Checks if any other plaves are part of me. |
void |
doubleMySize()
Double the size of my spatial object. |
GeoRelationship[] |
getConnectedToMe()
|
double |
getDirection()
|
GeoRelationship |
getGeoRelationship(GeoPlace target)
Will return the GeoRelationship to the target GeoPlace if it exists. |
java.lang.String |
getId()
The same as the RDF url for the node the object was based on. |
double |
getLength()
|
GeoPoint |
getMidpoint()
|
java.lang.String[] |
getMyAnnotions()
|
GeoRelationship[] |
getMyConnections()
|
GeoEvent[] |
getMyEvents()
|
GeoFeature |
getMyFeatureObject()
|
GeoMap |
getMyGeoMap()
|
int |
getMyLayerNum()
|
GeoPolyline |
getMyLine()
|
GeoPolygon |
getMyPolygon()
|
java.lang.String |
getMyPreferredName()
|
double |
getMySize()
|
double |
getMySizeX()
|
double |
getMySizeY()
|
int |
getRelationshipCount()
|
int |
getRelationshipCountWithBetweenRelationship()
|
int |
getRelationshipCountWithDirection()
|
int |
getRelationshipCountWithDistance()
|
int |
getRelationshipCountWithPartRelationship()
|
GeoPlace[] |
getTheOnesIAmBetween()
|
java.lang.String[] |
getTypes()
|
double |
getWidth()
|
void |
interpretMeasurements()
Interpret measurements and decide if it is a point, line or polygon, then create the spatial object with coordinates. |
boolean |
moveMeToTheBorder(GeoPlace theBorderOfThis,
double direction)
|
void |
moveMyGeos(double offsetX,
double offsetY)
Move all the geographical objects I have. |
int |
myLayerSize()
|
java.lang.String |
putMeBetween(GeoPlace place1,
GeoPlace place2)
Put this GeoPlace object between the two others. |
boolean |
rotateMyGeometryAccordingToDirection()
|
void |
setDirection(double direction)
|
void |
setLength(double length)
|
void |
setMyLayerNum(int myLayerNum)
|
void |
setMyLine(GeoPolyline myLine)
|
GeoPoint |
setMyLocation(double x,
double y)
Set my midpoint location. |
void |
setMyMidpoint(GeoPoint myMidpoint)
Midpoint has a double function, both as the point location of this place, or as the midpoint for a line or polygon location. |
void |
setMyPolygon(double x1,
double y1,
double x2,
double y2)
Sets my polygon as the simplest possible polygon: rectangle parallel to x and y axis of coordinate system. |
void |
setMyPolygon(GeoPolygon myPoly)
|
void |
setMyPreferredName(java.lang.String myPreferredName)
|
void |
setWidth(double width)
|
static GeoPlace[] |
toGeoPlaceArr(ExtendableObjectList objList)
Convert an ExtendableObjectList containing GeoPlace objects to a GeoPlace array, removing null elements. |
java.lang.String |
toString()
|
Methods inherited from class no.uio.edd.utils.geoutils.GeoFeature |
---|
getGmlFooter, getGmlHeader |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
int relationshipCounter
Constructor Detail |
---|
public GeoPlace(java.lang.String id, GeoMap inGeoMap)
id
- The same as the RDF url for the node the object was based on.myPreferredName
- Method Detail |
---|
public java.lang.String asGML()
GeoFeature
asGML
in interface GeoMaplike
asGML
in class GeoFeature
public void setMyMidpoint(GeoPoint myMidpoint)
myMidpoint
- the myMidpoint to setpublic GeoPolyline getMyLine()
public void setMyLine(GeoPolyline myLine)
myLine
- the myLine to setpublic GeoPolygon getMyPolygon()
public void setMyPolygon(double x1, double y1, double x2, double y2)
x1
- Coordinate 1.y1
- Coordinate 1.x2
- Coordinate 2.y2
- Coordinate 2.public void setMyPolygon(GeoPolygon myPoly)
myPoly
- The polygon to set.public java.lang.String getMyPreferredName()
public void setMyPreferredName(java.lang.String myPreferredName)
myPreferredName
- the myPreferredName to setpublic java.lang.String getId()
public java.lang.String asCoordList()
asCoordList
in class GeoFeature
public GeoRelationship[] getMyConnections()
public GeoRelationship[] getConnectedToMe()
public GeoEvent[] getMyEvents()
public GeoRelationship getGeoRelationship(GeoPlace target)
target
- The target of the relationship.
public GeoRelationship addGeoRelationshipToMe(GeoRelationship newRel)
newRel
- The new relationship.
public java.lang.String addAnnotation(java.lang.String newAnn)
newAnn
- The new annotation.
public java.lang.String[] getMyAnnotions()
public java.lang.String toString()
toString
in class java.lang.Object
public double getLength()
public void setLength(double length)
length
- the length to setpublic double getWidth()
public void setWidth(double width)
width
- the width to setpublic double getDirection()
public void setDirection(double direction)
direction
- the direction to setpublic java.lang.String[] getTypes()
public void addType(java.lang.String type)
type
- the type to addpublic int getMyLayerNum()
public void setMyLayerNum(int myLayerNum)
myLayerNum
- the myLayerNum to setpublic GeoEvent addEvent(java.lang.String id)
id
- The ID of the new event.
public static GeoPlace[] toGeoPlaceArr(ExtendableObjectList objList)
objList
- The object list.
public boolean doIHaveParts()
public void interpretMeasurements()
public GeoFeature getMyFeatureObject()
public int myLayerSize()
public GeoMap getMyGeoMap()
public GeoPoint getMidpoint()
getMidpoint
in class GeoFeature
public GeoPoint setMyLocation(double x, double y)
x
- New X location.y
- New Y location.
public void moveMyGeos(double offsetX, double offsetY)
offsetX
- Movement in X direction.offsetY
- Movement in Y direction.public double getMySize()
public void doubleMySize()
public boolean coveredByMe(GeoPlace gp)
public GeoPlace[] getTheOnesIAmBetween() throws GeoModelLocationException
GeoModelLocationException
public java.lang.String putMeBetween(GeoPlace place1, GeoPlace place2) throws GeoModelLocationException
place1
- The first place.place2
- The second place.
GeoModelLocationException
public boolean moveMeToTheBorder(GeoPlace theBorderOfThis, double direction)
public double getMySizeX()
public double getMySizeY()
public int getRelationshipCount()
public int countRelationshipsWithoutSpec()
public int getRelationshipCountWithDirection()
public int getRelationshipCountWithDistance()
public int getRelationshipCountWithPartRelationship()
public int getRelationshipCountWithBetweenRelationship()
public boolean rotateMyGeometryAccordingToDirection()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |