[FOLD] tidy up construction
[FOLD] Move definitions to header
[FOLD] template peer on Protocol