cvs: pear /File_DICOM/DICOM Element.php

From: Date: Tue, 09 Sep 2003 09:51:46 +0000
Subject: cvs: pear /File_DICOM/DICOM Element.php
Groups: php.pear.cvs 
Request: Send a blank email to pear-cvs+get-12568@lists.php.net to get a copy of this message
xnoguer Tue Sep 9 05:51:46 2003 EDT Modified files: /pear/File_DICOM/DICOM Element.php Log: code clean up. Don't require PEAR anymore Index: pear/File_DICOM/DICOM/Element.php diff -u pear/File_DICOM/DICOM/Element.php:1.2 pear/File_DICOM/DICOM/Element.php:1.3 --- pear/File_DICOM/DICOM/Element.php:1.2 Mon Aug 25 10:34:30 2003 +++ pear/File_DICOM/DICOM/Element.php Tue Sep 9 05:51:46 2003 @@ -16,9 +16,7 @@ // | Author: Xavier Noguer <xnoguer@php.net> | // +----------------------------------------------------------------------+ // -// $Id: Element.php,v 1.2 2003/08/25 14:34:30 xnoguer Exp $ - -require_once('PEAR.php'); +// $Id: Element.php,v 1.3 2003/09/09 09:51:46 xnoguer Exp $ /** * This class defines DICOM file elements @@ -26,7 +24,7 @@ * @author Xavier Noguer <xnoguer@php.net> * @package File_DICOM */ -class File_DICOM_Element extends PEAR +class File_DICOM_Element { /** * Value Representations (DICOM Standard PS 3.5 Sect 6.2) @@ -66,12 +64,6 @@ ); /** - * Array of fieldnames - * @var array - */ - var $fieldnames = array('group','element','offset','name'); - - /** * Type of VR for this element * @var integer */ @@ -149,9 +141,9 @@ $header = fread($IN, $diff); if (isset($dictref[$group][$element])) { - list($code,$name) = $dictref[$group][$element]; + list($code, $numa, $name) = $dictref[$group][$element]; } else { - list($code, $name) = array("--", "UNKNOWN"); + list($code, $numa, $name) = array("--", "UNKNOWN"); } // Read in the value field. Certain fields need to be decoded. @@ -190,10 +182,11 @@ $this->code = $code; $this->length = $length; // why save header?? - $this->header = $header; - foreach ($this->fieldnames as $var) { - $this->$var = $$var; - } + $this->header = $header; + $this->element = $element; + $this->group = $group; + $this->name = $name; + $this->offset = $offset; } /**

« previous php.pear.cvs (#12568) next »