II. Server Side Services

II-3. View Services

VS001:

VS001-1 setSendPoint

void setSendPoint()

This is a two-way method that sets SDM to accept a users mouse click and connect it to the earth coordinates. After the mouse click, the coordinates of the clicked point are sent to the Client through a Client Method, receivePoint (see Section III).

VS001-2 getPoint

void getPoint()

This is a one-way (synchronous) version of VS001-1. This method is used in conjunction with isOpComplete, getX and getY. After calling getPoint, the client must call isOpComplete at regular intervals, until it returns TRUE. After that, and only after that, is it safe to call getX and getY.

VS001-3 getX

string getX()

This method gets the projected easting coordinate (or longitude, if the server is in the Geodetic mode) associated with the user’s mouse click (on the server side). The returned string is either the ASCII version of a double precision real number, i.e. a projected coordinate, or has the form given in PS007.

VS001-4 getY

string getY()

This method gets the projected Northing coordinate (or latitude, if the server is in the Geodetic mode) associated with the user’s mouse click (on the server side). The returned string is either the ASCII version of a double precision real number, i.e. a projected coordinate, or has the form given in PS007.

VS001-5 isOpComplete

Bool isOpComplete()

This method confirms whether or not the user clicks the mouse.

VS001-6 setSendUserRect

void setSendUserRect()

This is a two-way (asynchronous) method that sets SDM to allow the user to drag a rectangle. When the mouse is released, the SW and NE coordinates of the rectangle are sent to the Client through a Client Method, receiveUserRect. (Please refer to the Client Side Methods in Section IV for more information about this command.)

VS001-7 getUserRect

void getUserRect()

This is a one-way (synchronous) version of VS001-6. This method is used in conjunction with isOpComplete, getSWx, getSWy, getNEx, and getNEy. After calling getUserRect, the client must call isOpComplete at regular intervals, until it returns TRUE. After that, and only after that, is it safe to call getSWx, getSWy, getNEx, and getNEy.

VS001-8 getSWx

string getSWx()

This method gets the projected easting coordinate (or Longitude if the SDM is in Geodetic mode) associated with the South West corner of the user-defined (via mouse drag) rectangle after a call to getUserRect. The returned string is either the ASCII version of a double precision real number, i.e. a projected coordinate, or has the form given in PS007 (the Geodetic mode).

VS001-9 getSWy

string getSWy()

This method gets the projected northing coordinate (or Latitude if the SDM is in Geodetic mode) associated with the South West corner of the user-defined (via mouse drag) rectangle after a call to getUserRect. The returned string is either the ASCII version of a double precision real number, i.e. a projected coordinate, or has the form given in PS007 (the Geodetic mode).

VS001-10 getNEx

string getNEx()

This method gets the projected easting coordinate (or Longitude if the SDM is in Geodetic mode) associated with the North East corner of the  user-defined (via mouse drag) rectangle after a call to getUserRect. The returned string is either the ASCII version of a double precision real number, i.e. a projected coordinate, or has the form given in PS007 (the Geodetic mode).

VS001-11 getNEy

string getNEy()

This method gets the projected northing coordinate (or Latitude if the SDM is in Geodetic mode) associated with the North East corner of the user-defined (via mouse drag) rectangle after a call to getUserRect. The returned string is either the ASCII version of a double precision real number, i.e. a projected coordinate, or has the form given in PS007 (the Geodetic mode).

 

VS002: View Modification

VS002-1 setOverview

void setOverview()

This method resets the current view so as to display the entire map.

VS002-2 centerAtPoint

void centerAtPoint(string x , string y )

where x and y are respectively the projected Easting and Northing coordinates, (or Longitude and Latitude, if the server is in the Geodetic mode). Projected coordinates must be ASCII version of real numbers, while Geodetic coordinates must have the form given in PS007.

This method centers the current view on the given point.

VS002-3 zoomByPercent

void zoomByPercent(string percent , boolean inorout)

where percent = percentage of zoom-in or zoom-out, inorout = True: zoom-in False: zoom-out

This method zooms the current view by the given percentage, either in or out, as given by the second argument.

VS002-4 setDisplayedMapExtent

void setDisplayedMapExtent( string x1, string y1, string x2, string y2 )

where x1, y1, x2 and y2 are respectively the projected SW-corner Easting, SW-corner Northing, NE-corner Easting, and NE-corner Northing coordinates, (or SW-corner Longitude, SW-corner Latitude, NE-corner Longitude and NE-corner Latitude, if the server is in the Geodetic mode). Projected coordinates must be ASCII version of real numbers, while Geodetic coordinates must have the form given in PS007.

This method sets the geographical area to be displayed.

VS002-5 setZoomByRectMode

void setZoombyRectMode()

This method sets SDM to allow a user to click and drag a rectangle of any size on an SDM graphic window. When the mouse is released, the view zooms in such a way that the portion of the map within the rectangle fills the view.

VS002-6 getDisplayScale

int getDisplayScale()

This method returns the denominator of the scale of the current view, i.e. if the scale is 1:n, n is returned, rounded to the nearest integer.

VS002-7 printCurrentDisplay

void printCurrentDisplay()

This method invokes the SDM print dialog. If the user responds by clicking OK (other parameters can be set), the current view is printed.

VS002-8 openNewView

void openNewView()

This method invokes the file Open dialog, which allows the user to browse and select a file. If the user responds by clicking Open then the selected dataset is opened in a new view in the SDM.

VS002-9 setSymbolizationOn

void setSymbolizationOn( BOOL flag )

This method turns symbolization on or off in the current view, depending on whether "flag" is TRUE or FALSE, respectively.

VS002-10 redrawCurrent

void redrawCurrent()

This method redraws (refreshes) the current view.

VS002-11 setNeutralMouseMode

void setNeutralMouseMode()

This method resets the mouse mode of the current view to the neutral state, i.e. mouse clicks in the view have no effect.

VS003 View Query

VS003-1 getDisplayedMapExtent

string extent = getDisplayedMapExtent()

Upon successful completion, the return value has the following format:

(x1,y1,x2,y2),

where x1, y1, x2 and y2 are, respectively, the projected SW-corner Easting, SW-corner Northing, NE-corner Easting, and NE-corner Northing coordinates, (or SW-corner Longitude, SW-corner Latitude, NE-corner Longitude and NE-corner Latitude, if the server is in the Geodetic mode). Projected coordinates are ASCII versions of real numbers, while Geodetic coordinates have the form given in PS007.

 

II-4. Server Side Services: Feature Services >>>>