CorePlugins

# Class: ServerImages Source Location: /coreplugins/images/server/ServerImages.php
### Class Overview
    PluginBase
       |
       --ServerPlugin
          |
          --ClientResponderAdapter
             |
             --ServerImages
Server part of Images plugin | ### Variables $angle $log | ### Constants IMAGES_WRITE_PATH MAX_IMAGES_WARNING | ### Methods __construct checkMapDimensions checkMaxImages drawMainmap getAngle getImage getImageBaseUrl getImageType getImageUrl handleCorePlugin initializeRequest isDrawQuery setupSizes
### Inherited Variables #### Class: ServerPlugin ServerPlugin::$config ServerPlugin::$serverContext #### Class: PluginBase PluginBase::$basePath PluginBase::$name PluginBase::$overriddenRequest | ### Inherited Methods #### Class: ClientResponderAdapter ClientResponderAdapter::handleDrawing() ClientResponderAdapter::handlePostDrawing() ClientResponderAdapter::handlePreDrawing() ClientResponderAdapter::initializeRequest() #### Class: ServerPlugin ServerPlugin::__construct() Constructor ServerPlugin::getConfig() ServerPlugin::getServerContext() ServerPlugin::initializeConfig() Initializes plugin configuration ServerPlugin::useExtendedInit() ServerPlugin::useExtendedRequest() ServerPlugin::useExtendedResult() #### Class: PluginBase PluginBase::__construct() Constructor PluginBase::account() Records an accounting message for plugins PluginBase::getBasePath() PluginBase::getExtendedName() PluginBase::getName() PluginBase::getRequest() Get plugin's request or result out of MapRequest or MapResult PluginBase::initialize() Plugin initialization (can be extended in custom plugins) PluginBase::initializeConfig() Initializes plugin PluginBase::preInitialize() Plugin pre initialization. In most cases, plugins should use PluginBase::replacePlugin() Returns name of parent plugin in case of plugin extension PluginBase::setBasePath() PluginBase::setExtendedName() PluginBase::setName()
### Class Details [line 28] Server part of Images plugin [ Top ] ### Class Variables #### $angle = 0 [line 45] Requested angle #### Tags:
access: | protected
Type: | float
[ Top ] #### $log = [line 50] #### Tags:
access: | private
Type: | Logger
Overrides: | Array
[ Top ] ### Class Methods ### constructor __construct [line 55]
`ServerImages __construct( )`
Constructor #### Tags:
access: | public
Overrides ServerPlugin::__construct() (Constructor) [ Top ] ### method checkMapDimensions [line 95]
`void checkMapDimensions( ImagesRequest $requ)`
Checks main map dimensions If limit mainmap dimensions are available, checks if asked map dims fit, else sets them to max authorized sizes. #### Tags:
access: | protected
#### Parameters:
ImagesRequest | $requ |
[ Top ] ### method checkMaxImages [line 240]
`void checkMaxImages( ServerContext $serverContext)`
Checks number of images in directory Adds a developper message if too many images. #### Tags:
access: | protected
#### Parameters:
ServerContext | $serverContext |
[ Top ] ### method drawMainmap [line 186]
`void drawMainmap( ImagesRequest $requ)`
Draws mainmap Uses MapServer draw() or drawQuery(). #### Tags:
access: | public
#### Parameters:
ImagesRequest | $requ |
[ Top ] ### method getAngle [line 350]
`float getAngle( )`
Returns angle that was requested by client #### Tags:
access: | public
[ Top ] ### method getImage [line 137]
`Image getImage( ms_Image $ms_image)`
Draws an image and returns an Image object #### Tags:
access: | protected
#### Parameters:
ms_Image | $ms_image | MapServer image
[ Top ] ### method getImageBaseUrl [line 108]
`string getImageBaseUrl( )`
#### Tags:
return: | The base URL where the generated images can be found.
access: | protected
[ Top ] ### method getImageType [line 172]
`string getImageType( )`
Returns the image type for main map. Image type is the outputformat identifier declared in mapfile. Gets the information from Layers plugin. #### Tags:
return: | The image type to use for drawing.
access: | protected
see: | ServerLayers::getImageType()
[ Top ] ### method getImageUrl [line 123]
`string getImageUrl( string $imagePath)`
Returns the complete URL to the image which is sent to the client. It uses the ResourceHandler to build this URL. #### Tags:
return: | The complete URL of the generated image.
access: | protected
#### Parameters:
string | $imagePath | the original path to the image
[ Top ] ### method handleCorePlugin [line 258]
`void handleCorePlugin( mixed $requ)`
#### Tags:
access: | public
see: | CoreProvider::handleCorePlugin()
[ Top ] ### method initializeRequest [line 63]
`void initializeRequest( mixed $requ)`
#### Tags:
access: | public
see: | ClientResponder::initializeRequest()
Overrides ClientResponderAdapter::initializeRequest() (parent method not documented) [ Top ] ### method isDrawQuery [line 156]
`boolean isDrawQuery( )`
Returns true if query must be drawn using MapServer Gets the information from Query plugin. #### Tags:
access: | protected
see: | ServerQuery::drawQuery()
[ Top ] ### method setupSizes [line 71]
`void setupSizes( ImagesRequest $requ)`
Sets main map dimensions into MapObj #### Tags:
access: | public
#### Parameters:
ImagesRequest | $requ |
[ Top ] ### Class Constants #### IMAGES_WRITE_PATH = 'images/' [line 39] Path where to write images, relative to the writable server path. [ Top ] #### MAX_IMAGES_WARNING = 500 [line 34] the number of generated images before issuing a warning [ Top ] Documentation generated on Fri, 21 Sep 2007 13:31:03 +0200 by phpDocumentor 1.3.0RC3