WebOffice Script API - WebOffice flex
A detailed documentation of the functions and their parameters can be found in the Java Script source file itself which is located in the WebOffice 10.9 R3 application directory <web application>\client_flexjs\js\api
The file ScriptApi.js contains almost the same functionality from the WebOffice html client. The other jsp files contain additional functionality that can be used in the WebOffice flex client. |
Currently implemented functions for the WebOffice 10.9 R3 Script API:
•scriptAPI.mapByCenterpointScale( fCenterX, fCenterY, iScale )
Query a new map via centre point and scale
•scriptAPI.addGraphicsLayer()
Adds a new graphics layer to the map
•scriptAPI.getGraphic( argOptions )
Generates a JSAPI Graphic object in the WebOffice context
•scriptAPI.getSketchViewModel ( argOptions )
Generates a JSAPI SketchViewModel object in the WebOffice context
Tool selection
•scriptAPI.getActiveTool()
Gets the currently activated tool
•scriptAPI.getActiveCustomTool()
Gets the currently activated custom tool
•scriptAPI.getCustomTool(sToolId)
Calls a custom tool
•scriptAPI.setTool() = function ( sToolId )
Activates a corresponding tool by tool ID (this function is only available for some tools: ToolSelect, ToolEdit, geoprocessing tools, custom Tools)
•client.api.closeActiveTool()
Closes all currently active tools (also works for simple and advanced custom tools)
GUI operations
•scriptAPI.addGUIModule( sName, sUrl, iState, sTitle, bCanBeClosed )
Adds a new GUI module to the WebOffice 10.9 R3 GUI
•scriptAPI.getGUIModule( argModule )
Gets the WebOffice 10.9 R3 GUI module for a nested iFrame
•scriptAPI.getGUIModuleByName( argName )
Gets the WebOffice 10.9 R3 GUI module by its name
•scriptAPI.removeGUIModule( module )
Removes the added GUI module from the name module
•scriptAPI.lockGUI: ( argOptions )
Locks the WebOffice 10.9 R3 GUI module; no more user interactions are possible until the lock is released again
Attributive queries
•scriptAPI.queryAttributive( sQueryname, sKeyname, sKeyvalue )
Shows result grid and selects features on map; map is updated by zooming in on result features
•scriptAPI.queryAttributiveMultiLayer( argQueries )
Displays result grid and selects features based on one or more layers on the map; map is updated by zooming in on result features
•scriptAPI.featureZoomAttributive( sQueryname, sKeyname, sKeyvalue )
No result grid; no feature selection on map, map is updated by zooming in on result features
•scriptAPI.featurePanAttributive( sQueryname, sKeyname, sKeyvalue )
No result grid; no feature selection on the map; map is updated by panning on result features
•scriptAPI.locateFeaturesAttributive( sQueryname, sKeyname, sKeyvalue )
No result grid, no feature selection on the map, no map update
•scriptAPI.displayResultAttributive( sQueryname, sKeyname, sKeyvalue )
Displays result grid; no feature selection on the map; no map update.
Snap
•scriptAPI.getSnapProfiles( callbackfct )
Fetches the configured snap profile
•scriptAPI.getSnap(sSnapProfileId, callbackfct)
Fetches the snap vertices of the current map section and the given snap profile.
Other
•scriptAPI.userMessage( sMessage, bAlert, bIsNote )
Shows a notification of the user
•scriptAPI.Env()
Returns a javascript object containing basic properties of the WebOffice 10.9 R3 environment
•scriptAPI.mapInfo()
Returns basic information about the map
•scriptAPI.log( sLogMessage )
Logs into the client-side WebOffice 10.9 R3 log monitor
•scriptAPI.mapByCenterpointScale: ( fCenterX, fCenterY, iScale )
Query a new map via center point and scale