Inital implementation

Not decided if this is the best route, or if I should create a function to offload some of the work.