Implements missing FlattenerLayer functions.

FlattenerLayer is missing some functions, like get_weight_decay.

This PR is about adding this missing functions.

A similar PR is needed for CompositeLayer, but I wait bartvm PR to be merged before sending one.