Moved the relevant pieces from zstream down into the two distinct sub
classes.