Code Duplication    Length = 12-12 lines in 5 locations

dist/jate/modules/Query/Query.php 5 locations

@@ 42-53 (lines=12) @@
39
        throw new JException("This connection name does not exist.", 1);
40
      $this->currentConnection = $this->connection["$_name"];
41
    }
42
    public function query( $_query ) {
43
      if(!is_string($_query))
44
        throw new JException("Parameter must be a string.", 1);
45
      if($this->currentConnection == null)
46
        throw new JException("No connection selected.", 1);
47
      try {
48
        $temp = $this->currentConnection->database->query($_query);
49
      } catch (Exception $e) {
50
        throw new JException($e->getMessage(), 1);
51
      }
52
      return $temp;
53
    }
54
    public function queryInsert( $_query ) {
55
      if(!is_string($_query))
56
        throw new JException("Parameter must be a string.", 1);
@@ 54-65 (lines=12) @@
51
      }
52
      return $temp;
53
    }
54
    public function queryInsert( $_query ) {
55
      if(!is_string($_query))
56
        throw new JException("Parameter must be a string.", 1);
57
      if($this->currentConnection == null)
58
        throw new JException("No connection selected.", 1);
59
      try {
60
        $temp = $this->currentConnection->database->queryInsert($_query);
61
      } catch (Exception $e) {
62
        throw new JException($e->getMessage(), 1);
63
      }
64
      return $temp;
65
    }
66
    public function queryFetch( $_query ) {
67
      if(!is_string($_query))
68
        throw new JException("Parameter must be a string.", 1);
@@ 66-77 (lines=12) @@
63
      }
64
      return $temp;
65
    }
66
    public function queryFetch( $_query ) {
67
      if(!is_string($_query))
68
        throw new JException("Parameter must be a string.", 1);
69
      if($this->currentConnection == null)
70
        throw new JException("No connection selected.", 1);
71
      try {
72
        $temp = $this->currentConnection->database->queryFetch($_query);
73
      } catch (Exception $e) {
74
        throw new JException($e->getMessage(), 1);
75
      }
76
      return $temp;
77
    }
78
    public function queryArray( $_query ) {
79
      if(!is_string($_query))
80
        throw new JException("Parameter must be a string.", 1);
@@ 78-89 (lines=12) @@
75
      }
76
      return $temp;
77
    }
78
    public function queryArray( $_query ) {
79
      if(!is_string($_query))
80
        throw new JException("Parameter must be a string.", 1);
81
      if($this->currentConnection == null)
82
        throw new JException("No connection selected.", 1);
83
      try {
84
        $temp = $this->currentConnection->database->queryArray($_query);
85
      } catch (Exception $e) {
86
        throw new JException($e->getMessage(), 1);
87
      }
88
      return $temp;
89
    }
90
    public function newTable( $_query ) {
91
      if(!is_string($_query))
92
        throw new JException("Parameter must be a string.", 1);
@@ 90-101 (lines=12) @@
87
      }
88
      return $temp;
89
    }
90
    public function newTable( $_query ) {
91
      if(!is_string($_query))
92
        throw new JException("Parameter must be a string.", 1);
93
      if($this->currentConnection == null)
94
        throw new JException("No connection selected.", 1);
95
      try {
96
        $temp = $this->currentConnection->database->newTable($_query);
97
      } catch (Exception $e) {
98
        throw new JException($e->getMessage(), 1);
99
      }
100
      return $temp;
101
    }
102
  }
103
?>
104