What causes the error in my custom module for OpenLayers 3?
Looks like a mismatch between your annotation (the @ in the comment above your class) and your class declaration. 

But you should post your code for more details.