Author: Kore Nordmann Date: 2007-02-07 16:13:27 +0100 (Wed, 07 Feb 2007) New Revision: 4630
Log: - Added simple private __toString method for coordinates and vectors for debugging Modified: trunk/Graph/src/structs/coordinate.php Modified: trunk/Graph/src/structs/coordinate.php =================================================================== --- trunk/Graph/src/structs/coordinate.php 2007-02-07 14:16:25 UTC (rev 4629) +++ trunk/Graph/src/structs/coordinate.php 2007-02-07 15:13:27 UTC (rev 4630) @@ -53,6 +53,17 @@ $this->x = $properties['x']; $this->y = $properties['y']; } + + /** + * Returns simple string representation of coordinate + * + * @return string + * @ignore + */ + public function __toString() + { + return sprintf( '( %.2f, %.2f )', $this->x, $this->y ); + } } ?> -- svn-components mailing list svn-components@lists.ez.no http://lists.ez.no/mailman/listinfo/svn-components