| [ Index ] |
PHP Cross Reference of MantisBT |
[Summary view] [Print] [Text view]
1 <?php 2 # MantisBT - A PHP based bugtracking system 3 # Copyright (C) 2002 - 2011 MantisBT Team - mantisbt-dev@lists.sourceforge.net 4 # MantisBT is free software: you can redistribute it and/or modify 5 # it under the terms of the GNU General Public License as published by 6 # the Free Software Foundation, either version 2 of the License, or 7 # (at your option) any later version. 8 # 9 # MantisBT is distributed in the hope that it will be useful, 10 # but WITHOUT ANY WARRANTY; without even the implied warranty of 11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 # GNU General Public License for more details. 13 # 14 # You should have received a copy of the GNU General Public License 15 # along with MantisBT. If not, see <http://www.gnu.org/licenses/>. 16 17 /** 18 * Mapper class 19 * 20 * it will store the ( type, old, new ) triplet for later retrieval 21 */ 22 class ImportXml_Mapper { 23 private $issue = array( ); 24 25 public function add( $type, $old, $new ) { 26 $this->{$type}[ $old ] = $new; 27 } 28 29 public function exists( $type, $id ) { 30 return array_key_exists( $id, $this->{$type} ); 31 } 32 33 public function getNewID( $type, $old ) { 34 if( $this->exists( $type, $old ) ) { 35 return $this->{$type}[ $old ]; 36 } else { 37 return $old; 38 } 39 } 40 41 public function getAll( $type ) { 42 return $this->{$type}; 43 } 44 }
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
| Generated: Thu Jul 28 15:48:31 2011 | Cross-referenced by PHPXref 0.7 |