1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
<?php

  class DataSessionStorage extends DataSessionStorage {


    protected $storage_key = null;


    public function __construct($storage_key) {
      if(false === isset($_SESSION['data_storage'][$storage_key])) {
        $_SESSION['data_storage'][$storage_key] = array();
      }
      
      $this->storage_key = $storage_key;
      $this->holder =& $_SESSION['data_storage'][$storage_key];
    }


    public function removeAll() {
      unset($_SESSION['data_storage'][$this->storage_key]);
    }
  }