Common
[ class tree: Common ] [ index: Common ] [ all elements ]

Class: UrlProvider

Source Location: /common/ResourceHandler.php

Class Overview


Abstract class for URL provider objects


Author(s):

Variables

Methods


Child classes:

SymlinkUrlProvider
Url provider for accessing files directly through the web server
MiniproxyUrlProvider
Url provider for accessing files through a mini-proxy

Class Details

[line 31]
Abstract class for URL provider objects

Extending classes have to provide URL's from a set of parameters in different contexts. For instance, return an URL for accessing files in a plugin htdocs directory.




Tags:

abstract:  


[ Top ]


Class Variables

$projectHandler =

[line 36]

The project handler to use for getting current project name



Tags:

access:  protected

Type:   ProjectHandler


[ Top ]



Class Methods


constructor __construct [line 42]

UrlProvider __construct( ProjectHandler $projectHandler)

Constructor



Tags:

access:  public


Parameters:

ProjectHandler   $projectHandler  

[ Top ]

method getGeneratedUrl [line 75]

void getGeneratedUrl( string $resource)

Returns an URL to access files inside the directory of generated files (like generated mapserver images, pdf files, ...) This can be used for server or client resources.



Tags:

abstract:  
access:  public


Overridden in child classes as:

SymlinkUrlProvider::getGeneratedUrl()
MiniproxyUrlProvider::getGeneratedUrl()

Parameters:

string   $resource   the resource to access (this is the resource name relative to the directory of generated files (www-data usually))

[ Top ]

method getHtdocsUrl [line 55]

void getHtdocsUrl( string $plugin, string $project, string $resource)

Returns the URL for resources in htdocs directory (may be in projects and plugins) This is only relevent for client resources.



Tags:

abstract:  
access:  public


Overridden in child classes as:

SymlinkUrlProvider::getHtdocsUrl()
MiniproxyUrlProvider::getHtdocsUrl()

Parameters:

string   $plugin   the plugin name
string   $project   the project name
string   $resource   the resource to access. It may contain a path, like css/style.css, or gfx/my_icon.png

[ Top ]

method getIconUrl [line 65]

void getIconUrl( string $project, string $mapId, string $resource)

Returns an URL to access icon images inside icons subdirectory where the mapfile is located.

This is only relevent for server resources.




Tags:

abstract:  
access:  public


Overridden in child classes as:

SymlinkUrlProvider::getIconUrl()
MiniproxyUrlProvider::getIconUrl()

Parameters:

string   $project   the project name
string   $mapId   the mapId to use
string   $resource   the resource to access (icon name, without path)

[ Top ]


Documentation generated on Wed, 6 Apr 2005 12:06:54 +0200 by phpDocumentor 1.3.0RC3