toiee/haikr — pull request #110 by big2men (2014-03-06 11:26:03+00:00)
Title: Modify plugin class

Add Plugin counter class PluginCounter.
And, modify Plugin class to using PluginCounter on create a instance.
You can get the number of a plugin instance `$plugin->getId();`

## MUST

### :exclamation: Overriding constructor
If you override `__construct`, call `parent::__construct` at the top.

I found and fixed below plugin overided constructor.
* ColsPlugin

### :exclamation: Using getId
If you already declare the function `getId()` or call counting feature, delete them and use this counting feature.

## PluginCounter

This class has count list of Plugins.

```javascript
{
IconPlugin: 1,
ColsPlugin: 10,
:
}
```

### Usage

* increment: `PluginCounter::inc('IconPlugin')`
* get count: `PluginCounter::get('IconPlugin');`
* get all count: `PluginCounter::all();`