[ Index ]
 

Code source de vtiger CRM 5.0.2

Accédez au Source d'autres logiciels libresSoutenez Angelica Josefina !

title

Body

[fermer]

/Image/Graph/ -> Common.php (sommaire)

Image_Graph - Main class for the graph creation. 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: Common.php,v 1.16 2006/02/28 22:48:07 nosey Exp $
Poids: 313 lignes (10 kb)
Inclus ou requis: 4 fois
Référencé: 0 fois
Nécessite: 2 fichiers
 Image/Canvas.php
 Image/Graph.php

Définit 1 class

Image_Graph_Common:: (10 méthodes):
  Image_Graph_Common()
  _reset()
  _setParent()
  hide()
  _getCanvas()
  add()
  addNew()
  _error()
  _updateCoords()
  _done()

Définit 10 fonctions

  is_a()

Classe: Image_Graph_Common  - X-Ref

The ultimate ancestor of all Image_Graph classes.

This class contains common functionality needed by all Image_Graph classes.

Image_Graph_Common()   X-Ref
Constructor [Image_Graph_Common]


_reset()   X-Ref
Resets the elements


_setParent(& $parent)   X-Ref
Sets the parent. The parent chain should ultimately be a GraPHP object

param: Image_Graph_Common $parent The parent

hide()   X-Ref
Hide the element


_getCanvas()   X-Ref
Get the canvas

return: Image_Canvas The canvas

add(& $element)   X-Ref
Adds an element to the objects element list.

The new Image_Graph_elements parent is automatically set.

param: Image_Graph_Common $element The new Image_Graph_element
return: Image_Graph_Common The new Image_Graph_element

addNew($class, $params = null, $additional = false)   X-Ref
Creates an object from the class and adds it to the objects element list.

Creates an object from the class specified and adds it to the objects
element list. If only one parameter is required for the constructor of
the class simply pass this parameter as the $params parameter, unless the
parameter is an array or a reference to a value, in that case you must
'enclose' the parameter in an array. Similar if the constructor takes
more than one parameter specify the parameters in an array.

param: string $class The class for the object
param: mixed $params The paramaters to pass to the constructor
return: Image_Graph_Common The new Image_Graph_element

_error($text, $params = false, $error_code = IMAGE_GRAPH_ERROR_GENERIC)   X-Ref
Shows an error message box on the canvas

param: string $text The error text
param: array $params An array containing error specific details
param: int $error_code Error code

_updateCoords()   X-Ref
Causes the object to update all sub elements coordinates

(Image_Graph_Common, does not itself have coordinates, this is basically
an abstract method)


_done()   X-Ref
Causes output to canvas

The last method to call. Calling Done causes output to the canvas. All
sub elements done() method will be invoked

return: bool Was the output 'good' (true) or 'bad' (false).

Fonctions
Fonctions qui ne font pas partie d'une Classe:

is_a($object, $class_name)   X-Ref
Check if an object is of a given class, this function is available as of PHP 4.2.0, so if it exist it will not be declared

param: object $object The object to check class for
param: string $class_name The name of the class to check the object for
return: bool Returns TRUE if the object is of this class or has this class as one of its parents



Généré le : Sun Feb 25 10:22:19 2007 par Balluche grâce à PHPXref 0.7