Skip to content

Commit

Permalink
added reset command
Browse files Browse the repository at this point in the history
  • Loading branch information
itsmill3rtime committed Aug 16, 2018
1 parent a1ece2b commit b22e31d
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion src/MySQLFileTool.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@ public function __construct($table, $keys, $chunk_size)
$this->_table = $table;
$this->_keys = $keys;
$this->_chunk_size = $chunk_size;

}

/**
Expand Down Expand Up @@ -97,6 +96,8 @@ public function import()
dump('file: ' . $file . ' failed' . $exception);
}
}

$this->reset();
}

/**
Expand Down Expand Up @@ -132,4 +133,15 @@ private function destroyFile($file)
{
@unlink($file);
}

/**
*
*/
public function reset()
{
$this->_files = [];
$this->_active_file = null;
$this->_current_index = 0;
$this->_active_file_reference = null;
}
}

0 comments on commit b22e31d

Please sign in to comment.