Refactor rebind code, and tidy

Please merge https://github.com/apache/incubator-brooklyn/pull/308 first
Whitespace around binary operators, please.