public static StreamStatus forCode(int code) {
        for (StreamStatus status : values()) {
            if (status.getCode() == code) {
                return status;
            }
        }
        throw new IllegalStateException(String.format("Illegal code=%s for StreamStatus", code));
    }
Checks whether the given status allows deleting operate.
inlong-manager/manager-common/src/main/java/org/apache/inlong/manager/common/enums/StreamStatus.java