encapsulate plugins in class