base pub sub class