Browse files

Image_GIS->Image_GIS2

git-svn-id: http://svn.php.net/repository/pear/packages/Image_GIS2/trunk@156395 c90b9560-bf6c-de11-be94-00142212c4b1
  • Loading branch information...
1 parent 2ea702f commit 671a26e7e51ad6084ec1517b1e58bf919801358f @sebastianbergmann sebastianbergmann committed Apr 17, 2004
View
29 GIS.php
@@ -17,19 +17,19 @@
//
require_once 'Image/Color.php';
-require_once 'Image/GIS/Parser.php';
-require_once 'Image/GIS/Renderer.php';
+require_once 'Image/GIS2/Parser.php';
+require_once 'Image/GIS2/Renderer.php';
/**
* The following example draws the region around the
* German city of Kiel which is Jan's home town:
*
* <code>
* <?php
- * require_once 'Image/GIS.php';
+ * require_once 'Image/GIS2.php';
*
* // Create new map.
- * $map = new Image_GIS(
+ * $map = new Image_GIS2(
* array(
* 'width' => 960,
* 'height' => 1280,
@@ -62,9 +62,9 @@
* @copyright Copyright &copy; 2002-2004 Jan Kneschke <jan@kneschke.de> and Sebastian Bergmann <sb@sebastian-bergmann.de>
* @license http://www.php.net/license/3_0.txt The PHP License, Version 3.0
* @category Image
- * @package Image_GIS
+ * @package Image_GIS2
*/
-class Image_GIS {
+class Image_GIS2 {
/**
* Set to TRUE to enable debugging.
*
@@ -73,16 +73,16 @@ class Image_GIS {
private $debug;
/**
- * Image_GIS_Parser sub-class object.
+ * Image_GIS2_Parser sub-class object.
*
- * @var Image_GIS_Parser $parser
+ * @var Image_GIS2_Parser $parser
*/
private $parser;
/**
- * Image_GIS_Renderer sub-class object.
+ * Image_GIS2_Renderer sub-class object.
*
- * @var Image_GIS_Renderer $renderer
+ * @var Image_GIS2_Renderer $renderer
*/
private $renderer;
@@ -137,7 +137,6 @@ public function addDataFile($dataFile, $color) {
*
* @return array
* @access public
- * @since Image_GIS 1.0.1
*/
public function getRange() {
return $this->renderer->getRange();
@@ -166,15 +165,15 @@ public function saveImage($filename) {
}
/**
- * Sets the Image_GIS_Parser sub-class to be used
+ * Sets the Image_GIS2_Parser sub-class to be used
* to parse a data file.
*
* @param string $parser
* @param boolean $cache
* @access public
*/
public function setParser($parser, $cache) {
- $this->parser = Image_GIS_Parser::factory($parser, $cache, $this->debug);
+ $this->parser = Image_GIS2_Parser::factory($parser, $cache, $this->debug);
}
/**
@@ -191,14 +190,14 @@ public function setRange($x1, $x2, $y1, $y2) {
}
/**
- * Sets the Image_GIS_Renderer sub-class to be used
+ * Sets the Image_GIS2_Renderer sub-class to be used
* to render an image.
*
* @param string $renderer
* @access public
*/
public function setRenderer($renderer, $width, $height) {
- $this->renderer = Image_GIS_Renderer::factory($renderer, $width, $height, $this->debug);
+ $this->renderer = Image_GIS2_Renderer::factory($renderer, $width, $height, $this->debug);
}
/**
View
6 GIS/LineSet.php → GIS2/LineSet.php
@@ -23,9 +23,9 @@
* @copyright Copyright &copy; 2002-2004 Jan Kneschke <jan@kneschke.de> and Sebastian Bergmann <sb@sebastian-bergmann.de>
* @license http://www.php.net/license/3_0.txt The PHP License, Version 3.0
* @category Image
- * @package Image_GIS
+ * @package Image_GIS2
*/
-class Image_GIS_LineSet {
+class Image_GIS2_LineSet {
/**
* @var array $color
*/
@@ -58,7 +58,7 @@ class Image_GIS_LineSet {
* @param string $color
* @access public
*/
- public function Image_GIS_LineSet($color = 'black') {
+ public function Image_GIS2_LineSet($color = 'black') {
$this->color = $color;
}
View
12 GIS/Parser.php → GIS2/Parser.php
@@ -17,7 +17,7 @@
//
require_once 'Cache/Lite.php';
-require_once 'Image/GIS/LineSet.php';
+require_once 'Image/GIS2/LineSet.php';
/**
* Parser Base Class.
@@ -26,9 +26,9 @@
* @copyright Copyright &copy; 2002-2004 Jan Kneschke <jan@kneschke.de> and Sebastian Bergmann <sb@sebastian-bergmann.de>
* @license http://www.php.net/license/3_0.txt The PHP License, Version 3.0
* @category Image
- * @package Image_GIS
+ * @package Image_GIS2
*/
-abstract class Image_GIS_Parser {
+abstract class Image_GIS2_Parser {
/**
* Cache.
*
@@ -64,7 +64,7 @@
* @param boolean $debug
* @access public
*/
- public function Image_GIS_Parser($cache, $debug) {
+ public function Image_GIS2_Parser($cache, $debug) {
if ($cache) {
$this->cache = new Cache_Lite;
}
@@ -82,9 +82,9 @@ public function Image_GIS_Parser($cache, $debug) {
* @access public
*/
public static function factory($parser, $cache, $debug) {
- include_once 'Image/GIS/Parser/' . $parser . '.php';
+ include_once 'Image/GIS2/Parser/' . $parser . '.php';
- $class = 'Image_GIS_Parser_' . $parser;
+ $class = 'Image_GIS2_Parser_' . $parser;
$object = new $class($cache, $debug);
return $object;
View
14 GIS/Parser/E00.php → GIS2/Parser/E00.php
@@ -16,8 +16,8 @@
// $Id$
//
-require_once 'Image/GIS/LineSet.php';
-require_once 'Image/GIS/Parser.php';
+require_once 'Image/GIS2/LineSet.php';
+require_once 'Image/GIS2/Parser.php';
/**
* E00 Parser.
@@ -27,18 +27,18 @@
* @copyright Copyright &copy; 2002-2004 Jan Kneschke <jan@kneschke.de> and Sebastian Bergmann <sb@sebastian-bergmann.de>
* @license http://www.php.net/license/3_0.txt The PHP License, Version 3.0
* @category Image
- * @package Image_GIS
+ * @package Image_GIS2
*/
-class Image_GIS_Parser_E00 extends Image_GIS_Parser {
+class Image_GIS2_Parser_E00 extends Image_GIS2_Parser {
/**
* Constructor.
*
* @param boolean $cache
* @param boolean $debug
* @access public
*/
- public function Image_GIS_Parser_E00($cache, $debug) {
- $this->Image_GIS_Parser($cache, $debug);
+ public function Image_GIS2_Parser_E00($cache, $debug) {
+ $this->Image_GIS2_Parser($cache, $debug);
}
/**
@@ -50,7 +50,7 @@ public function Image_GIS_Parser_E00($cache, $debug) {
* @access public
*/
public function parseFile($dataFile, $color) {
- $lineSet = new Image_GIS_LineSet($color);
+ $lineSet = new Image_GIS2_LineSet($color);
if ($fp = @fopen($dataFile, 'r')) {
$numRecords = 0;
View
11 GIS/Renderer.php → GIS2/Renderer.php
@@ -26,10 +26,10 @@
* @copyright Copyright &copy; 2002-2004 Jan Kneschke <jan@kneschke.de> and Sebastian Bergmann <sb@sebastian-bergmann.de>
* @license http://www.php.net/license/3_0.txt The PHP License, Version 3.0
* @category Image
- * @package Image_GIS
+ * @package Image_GIS2
* @abstract
*/
-abstract class Image_GIS_Renderer {
+abstract class Image_GIS2_Renderer {
/**
* Set to TRUE to enable debugging.
*
@@ -69,7 +69,7 @@
* @param boolean $debug
* @access public
*/
- public function Image_GIS_Renderer($width, $height, $debug) {
+ public function Image_GIS2_Renderer($width, $height, $debug) {
$this->debug = $debug;
if ($width < 0 ||
@@ -97,8 +97,8 @@ public function Image_GIS_Renderer($width, $height, $debug) {
* @access public
*/
public static function factory($renderer, $width, $height, $debug) {
- if (@include_once('Image/GIS/Renderer/' . $renderer . '.php')) {
- $class = 'Image_GIS_Renderer_' . $renderer;
+ if (@include_once('Image/GIS2/Renderer/' . $renderer . '.php')) {
+ $class = 'Image_GIS2_Renderer_' . $renderer;
$object = new $class($width, $height, $debug);
return $object;
@@ -154,7 +154,6 @@ public function drawClippedLine($x1, $y1, $x2, $y2, $color) {
*
* @return array
* @access public
- * @since Image_GIS 1.0.1
*/
public function getRange() {
return array(
View
8 GIS/Renderer/GD.php → GIS2/Renderer/GD.php
@@ -16,7 +16,7 @@
// $Id$
//
-require_once 'Image/GIS/Renderer.php';
+require_once 'Image/GIS2/Renderer.php';
/**
* GD Renderer.
@@ -26,9 +26,9 @@
* @copyright Copyright &copy; 2002-2004 Jan Kneschke <jan@kneschke.de> and Sebastian Bergmann <sb@sebastian-bergmann.de>
* @license http://www.php.net/license/3_0.txt The PHP License, Version 3.0
* @category Image
- * @package Image_GIS
+ * @package Image_GIS2
*/
-class Image_GIS_Renderer_GD extends Image_GIS_Renderer {
+class Image_GIS2_Renderer_GD extends Image_GIS2_Renderer {
/**
* GD Image Ressource.
*
@@ -63,7 +63,7 @@ public function __construct($width, $height, $debug) {
imagecolorallocate($this->image, 255, 255, 255);
}
- $this->Image_GIS_Renderer($width, $height, $debug);
+ $this->Image_GIS2_Renderer($width, $height, $debug);
}
/**
View
8 GIS/Renderer/SVG.php → GIS2/Renderer/SVG.php
@@ -16,7 +16,7 @@
// $Id$
//
-require_once 'Image/GIS/Renderer.php';
+require_once 'Image/GIS2/Renderer.php';
require_once 'XML/SVG.php';
/**
@@ -26,9 +26,9 @@
* @copyright Copyright &copy; 2002-2004 Jan Kneschke <jan@kneschke.de> and Sebastian Bergmann <sb@sebastian-bergmann.de>
* @license http://www.php.net/license/3_0.txt The PHP License, Version 3.0
* @category Image
- * @package Image_GIS
+ * @package Image_GIS2
*/
-class Image_GIS_Renderer_SVG extends Image_GIS_Renderer {
+class Image_GIS2_Renderer_SVG extends Image_GIS2_Renderer {
/**
* SVG Document.
*
@@ -52,7 +52,7 @@ class Image_GIS_Renderer_SVG extends Image_GIS_Renderer {
* @access public
*/
public function __construct($width, $height, $debug) {
- $this->Image_GIS_Renderer($width, $height, $debug);
+ $this->Image_GIS2_Renderer($width, $height, $debug);
$this->svg = new XML_SVG_Document(
array(
View
43 package.xml
@@ -40,7 +40,7 @@ produce images using GD or Scalable Vector Graphics (SVG).
</notes>
<filelist>
<dir name="/" baseinstalldir="Image">
- <dir name="GIS">
+ <dir name="GIS2">
<dir name="Parser">
<file role="php" name="E00.php"/>
</dir>
@@ -65,45 +65,4 @@ produce images using GD or Scalable Vector Graphics (SVG).
<dep type="pkg" rel="has">XML_SVG</dep>
</deps>
</release>
- <changelog>
- <release>
- <version>1.1.0</version>
- <state>stable</state>
- <date>2004-01-06</date>
- <notes>
-<![CDATA[
-+ Added caching of parsed data files.
-
-+ Added getRange() method to the Image_GIS and Image_GIS_Renderer
- classes.
-
-* Changed the Image_GIS constructor to accept an associative
- parameter array as its only argument.
-
- Note: This breaks backwards compatibility.
-
-* The SVG renderer now uses the XML_SVG package instead of the
- XML_Tree package.
-
-* Factored the handling of Line Sets out into a separate class.
-
-* Fixed handling of negative coordinates.
-
-* Fixed a bug that kept a debugging message from beeing printed.
-
-* Fixed incompatibilities with PHP 5.
-]]>
- </notes>
- </release>
- <release>
- <version>1.0.0</version>
- <state>stable</state>
- <date>2002-12-30</date>
- <notes>
-<![CDATA[
-* Initial release.
-]]>
- </notes>
- </release>
- </changelog>
</package>

0 comments on commit 671a26e

Please sign in to comment.