| [ Index ] |
|
Code source de vtiger CRM 5.0.2 |
[Code source] [Imprimer] [Statistiques]
Image_Graph - PEAR PHP OO Graph Rendering Utility. PHP versions 4 and 5
| Author: | Jesper Veggerby <pear.nosey@veggerby.dk> |
| Copyright: | Copyright (C) 2003, 2004 Jesper Veggerby Hansen |
| License: | http://www.gnu.org/copyleft/lesser.html LGPL License 2.1 |
| Version: | CVS: $Id: Trivial.php,v 1.10 2005/09/25 18:08:56 nosey Exp $ |
| Poids: | 260 lignes (8 kb) |
| Inclus ou requis: | 2 fois |
| Référencé: | 0 fois |
| Nécessite: | 1 fichier Image/Graph/Dataset.php |
Image_Graph_Dataset_Trivial:: (11 méthodes):
Image_Graph_Dataset_Trivial()
addPoint()
first()
last()
_getPointX()
_getPointY()
_getPointID()
_getPointData()
count()
_reset()
_next()
Classe: Image_Graph_Dataset_Trivial - X-Ref
Trivial data set, simply add points (x, y) 1 by 1| Image_Graph_Dataset_Trivial($dataArray = false) X-Ref |
| Image_Graph_Dataset_Trivial [Constructor] Pass an associated array ($data[$x] = $y) to the constructor for easy data addition. Alternatively (if multiple entries with same x value is required) pass an array with (x, y) values: $data[$id] = array('x' => $x, 'y' => $y); NB! If passing the 1st type array at this point, the x-values will also be used for ID tags, i.e. when using {@link Image_Graph_Fill_Array}. In the 2nd type the key/index of the "outermost" array will be the id tag (i.e. $id in the example) param: array $dataArray An associated array with values to the dataset |
| addPoint($x, $y = false, $ID = false) X-Ref |
| Add a point to the dataset $ID can contain either the ID of the point, i.e. 'DK', 123, 'George', etc. or it can contain values used for creation of the HTML image map. This is achieved using is an an associated array with the following values: 'url' The URL to create the link to 'alt' [optional] The alt text on the link 'target' [optional] The target of the link 'htmltags' [optional] An associated array with html tags (tag as key), fx. 'onMouseOver' => 'history.go(-1);', 'id' => 'thelink' param: int $x The X value to add param: int $y The Y value to add, can be omited param: var $ID The ID of the point |
| first() X-Ref |
| The first point return: array The last point |
| last() X-Ref |
| The last point return: array The first point |
| _getPointX($x) X-Ref |
| Gets a X point from the dataset param: var $x The variable to return an X value from, fx in a return: var The X value of the variable |
| _getPointY($x) X-Ref |
| Gets a Y point from the dataset param: var $x The variable to return an Y value from, fx in a return: var The Y value of the variable |
| _getPointID($x) X-Ref |
| Gets a ID from the dataset param: var $x The variable to return an Y value from, fx in a return: var The ID value of the variable |
| _getPointData($x) X-Ref |
| Gets point data from the dataset param: var $x The variable to return an Y value from, fx in a vector return: array The data for the point |
| count() X-Ref |
| The number of values in the dataset return: int The number of values in the dataset |
| _reset() X-Ref |
| Reset the intertal dataset pointer return: var The first X value |
| _next() X-Ref |
| Get the next point the internal pointer refers to and advance the pointer return: array The next point |
| Généré le : Sun Feb 25 10:22:19 2007 | par Balluche grâce à PHPXref 0.7 |