stream统一用closed判断