Implement codec classes