refactoring using cometclient base class