Brendan

This should be the last piece, code should be testable now