lib/Lime/App.php
public function set($key, $value) {

        $keys = \explode('/',$key);

        if (\count($keys)>5) return false;

        switch (\count($keys)){

          case 1:
            $this->registry[$keys[0]] = $value;
            break;

          case 2:
            $this->registry[$keys[0]][$keys[1]] = $value;
            break;

          case 3:
            $this->registry[$keys[0]][$keys[1]][$keys[2]] = $value;
            break;

          case 4:
            $this->registry[$keys[0]][$keys[1]][$keys[2]][$keys[3]] = $value;
            break;

          case 5:
            $this->registry[$keys[0]][$keys[1]][$keys[2]][$keys[3]][$keys[4]] = $value;
            break;
        }

        return $this;
    }
public function set($key, $value) {

        $keys = \explode('/',$key);

        if (\count($keys)>5) return false;

        switch (\count($keys)){

          case 1:
            $this->registry[$keys[0]] = $value;
            break;

          case 2:
            $this->registry[$keys[0]][$keys[1]] = $value;
            break;

          case 3:
            $this->registry[$keys[0]][$keys[1]][$keys[2]] = $value;
            break;

          case 4:
            $this->registry[$keys[0]][$keys[1]][$keys[2]][$keys[3]] = $value;
            break;

          case 5:
            $this->registry[$keys[0]][$keys[1]][$keys[2]][$keys[3]][$keys[4]] = $value;
            break;
        }

        return $this;
    }
public function set ( $ key , $ value ) { $ keys = \ explode ( '/' , $ key ) ; if ( \ count ( $ keys ) > 5 ) return false ; switch ( \ count ( $ keys ) ) { case 1 : $ this -> registry [ $ keys [ 0 ] ] = $ value ; break ; case 2 : $ this -> registry [ $ keys [ 0 ] ] [ $ keys [ 1 ] ] = $ value ; break ; case 3 : $ this -> registry [ $ keys [ 0 ] ] [ $ keys [ 1 ] ] [ $ keys [ 2 ] ] = $ value ; break ; case 4 : $ this -> registry [ $ keys [ 0 ] ] [ $ keys [ 1 ] ] [ $ keys [ 2 ] ] [ $ keys [ 3 ] ] = $ value ; break ; case 5 : $ this -> registry [ $ keys [ 0 ] ] [ $ keys [ 1 ] ] [ $ keys [ 2 ] ] [ $ keys [ 3 ] ] [ $ keys [ 4 ] ] = $ value ; break ; } return $ this ; }
Put a value in the Lime registry
@param String $key  Key name
@param Mixed $value  Value
Put a value in the Lime registry