[WIP] General API

This is a first attempt to implement the ideas in https://github.com/JuliaStats/RegERMs.jl/issues/3. 

*Current issue*: types and functions for losses (see, e.g., loss.jl; other files are only adapted for testing).

Next steps: tbd
The optimizer/solver should be a a subtype of ``RegressionSolver``, each solver should have its own ``solve`` or ``optimize`` function. 

We will potentially have many solvers, and the ``if optimizer == :sgd`` and ``elseif`` approach won't scale up.