## Class THotSpot

Description

THotSpot class.

THotSpot implements the basic functionality common to all hot spot shapes. Derived classes include TCircleHotSpot, TPolygonHotSpot and TRectangleHotSpot.

- abstract:
- since: 3.0
- version: $Id: TImageMap.php 2541 2008-10-21 15:05:13Z qiang.xue $
- author: Qiang Xue <qiang.xue@gmail.com>

Located in /Web/UI/WebControls/TImageMap.php (line 300)

    TComponent
       |
       --THotSpot

Direct descendents

Class | Description
--- | ---
TCircleHotSpot | Class TCircleHotSpot.
TRectangleHotSpot | Class TRectangleHotSpot.
TPolygonHotSpot | Class TPolygonHotSpot.

Method Summary
string getAccessKey ()
string getAlternateText ()
string getAttribute (mixed $name)
TAttributeCollection getAttributes ()
boolean getCausesValidation ()
string getCoordinates ()
boolean getHasAttributes ()
THotSpotMode getHotSpotMode ()
string getNavigateUrl ()
string getPostBackValue ()
string getShape ()
integer getTabIndex ()
string getTarget ()
string getValidationGroup ()
mixed getViewState (string $key, [mixed $defaultValue = null])
boolean hasAttribute (mixed $name)
string removeAttribute (string $name)
void render (THtmlWriter $writer)
void setAccessKey (string $value)
void setAlternateText (string $value)
void setAttribute (string $name, string $value)
void setCausesValidation (boolean $value)
void setHotSpotMode (THotSpotMode $value)
void setNavigateUrl (string $value)
void setPostBackValue (string $value)
void setTabIndex (integer $value)
void setTarget (string $value)
void setValidationGroup (string $value)
void setViewState (string $key, mixed $value, [mixed $defaultValue = null])
Methods
getAccessKey (line 348)

- return: the access key that allows you to quickly navigate to the HotSpot region. Defaults to ''.
- access: public

string getAccessKey ()
getAlternateText (line 364)

- return: the alternate text to display for a HotSpot object. Defaults to ''.
- access: public

string getAlternateText ()
getAttribute (line 534)

- return: attribute value, null if attribute does not exist
- access: public

string getAttribute (mixed $name)
getAttributes (line 508)

Returns the list of custom attributes.

Custom attributes are name-value pairs that may be rendered as HTML tags' attributes.

- return: the list of custom attributes
- access: public

TAttributeCollection getAttributes ()
getCausesValidation (line 444)

- return: whether postback event trigger by this hotspot will cause input validation, default is true
- access: public

boolean getCausesValidation ()
getCoordinates (line 343)

- return: coordinates defining the hotspot shape.
- access: public
- abstract:

string getCoordinates ()

Redefined in descendants as:

- TCircleHotSpot::getCoordinates()
- TRectangleHotSpot::getCoordinates()
- TPolygonHotSpot::getCoordinates()

getHasAttributes (line 494)

- return: whether the hotspot has custom attributes
- access: public

boolean getHasAttributes ()
getHotSpotMode (line 380)

- return: the behavior of a HotSpot object when it is clicked. Defaults to THotSpotMode::NotSet.
- access: public

THotSpotMode getHotSpotMode ()
getNavigateUrl (line 396)

- return: the URL to navigate to when a HotSpot object is clicked. Defaults to ''.
- access: public

string getNavigateUrl ()
getPostBackValue (line 412)

- return: a value that is post back when the HotSpot is clicked. Defaults to ''.
- access: public

string getPostBackValue ()
getShape (line 339)

- return: shape of the hotspot, can be 'circle', 'rect', 'poly', etc.
- access: public
- abstract:

string getShape ()

Redefined in descendants as:

- TCircleHotSpot::getShape()
- TRectangleHotSpot::getShape()
- TPolygonHotSpot::getShape()

getTabIndex (line 428)

- return: the tab index of the HotSpot region. Defaults to 0.
- access: public

integer getTabIndex ()
getTarget (line 477)

- return: the target window or frame to display the new page when the HotSpot region is clicked. Defaults to ''.
- access: public

string getTarget ()
getValidationGroup (line 460)

- return: the group of validators which the hotspot causes validation upon postback
- access: public

string getValidationGroup ()
getViewState (line 313)

Returns a viewstate value.

This function is very useful in defining getter functions for component properties that must be kept in viewstate.

- return: the viewstate value corresponding to $key
- access: protected

mixed getViewState (string $key, [mixed $defaultValue = null])

- string $key: the name of the viewstate value to be returned
- mixed $defaultValue: the default value. If $key is not found in viewstate, $defaultValue will be returned

hasAttribute (line 523)

- return: whether the named attribute exists
- access: public

boolean hasAttribute (mixed $name)
removeAttribute (line 557)

Removes the named attribute.

- return: attribute value removed, null if attribute does not exist.
- access: public

string removeAttribute (string $name)

- string $name: the name of the attribute to be removed.

render (line 569)

Renders this hotspot.

- access: public

void render (THtmlWriter $writer)

- THtmlWriter $writer

setAccessKey (line 356)

- access: public

void setAccessKey (string $value)

- string $value: the access key that allows you to quickly navigate to the HotSpot region.

setAlternateText (line 372)

- access: public

void setAlternateText (string $value)

- string $value: the alternate text to display for a HotSpot object.

setAttribute (line 547)

Sets a custom hotspot attribute.

- access: public

void setAttribute (string $name, string $value)

- string $name: attribute name
- string $value: value of the attribute

setCausesValidation (line 452)

- access: public

void setCausesValidation (boolean $value)

- boolean $value: whether postback event trigger by this hotspot will cause input validation

setHotSpotMode (line 388)

- access: public

void setHotSpotMode (THotSpotMode $value)

- THotSpotMode $value: the behavior of a HotSpot object when it is clicked.

setNavigateUrl (line 404)

- access: public

void setNavigateUrl (string $value)

- string $value: the URL to navigate to when a HotSpot object is clicked.

setPostBackValue (line 420)

- access: public

void setPostBackValue (string $value)

- string $value: a value that is post back when the HotSpot is clicked.

setTabIndex (line 436)

- access: public

void setTabIndex (integer $value)

- integer $value: the tab index of the HotSpot region.

setTarget (line 486)

- access: public

void setTarget (string $value)

- string $value: the target window or frame to display the new page when the HotSpot region is clicked.

setValidationGroup (line 468)

- access: public

void setValidationGroup (string $value)

- string $value: the group of validators which the hotspot causes validation upon postback

setViewState (line 328)

Sets a viewstate value.

This function is very useful in defining setter functions for control properties that must be kept in viewstate. Make sure that the viewstate value must be serializable and unserializable.

- access: protected

void setViewState (string $key, mixed $value, [mixed $defaultValue = null])

- string $key: the name of the viewstate value
- mixed $value: the viewstate value to be set
- mixed $defaultValue: default value. If $value===$defaultValue, the item will be cleared from the viewstate.

#### Inherited Methods

Inherited From TComponent

> TComponent::addParsedObject()
> TComponent::attachEventHandler()
> TComponent::canGetProperty()
> TComponent::canSetProperty()
> TComponent::createdOnTemplate()
> TComponent::detachEventHandler()
> TComponent::evaluateExpression()
> TComponent::evaluateStatements()
> TComponent::getEventHandlers()
> TComponent::getSubProperty()
> TComponent::hasEvent()
> TComponent::hasEventHandler()
> TComponent::hasProperty()
> TComponent::raiseEvent()
> TComponent::setSubProperty()
> TComponent::__get()
> TComponent::__set()

Documentation generated on Mon, 22 Feb 2010 12:17:57 +0000 by phpDocumentor 1.3.0RC4