private void validate() {
    if (isStreaming) {
      if (startingStrategy == StreamingStartingStrategy.INCREMENTAL_FROM_SNAPSHOT_ID) {
        Preconditions.checkArgument(
            startSnapshotId != null,
            "Invalid starting snapshot id for SPECIFIC_START_SNAPSHOT_ID strategy: null");
        Preconditions.checkArgument(
            startSnapshotTimestamp == null,
            "Invalid starting snapshot timestamp for SPECIFIC_START_SNAPSHOT_ID strategy: not null");
      }
      if (startingStrategy == StreamingStartingStrategy.INCREMENTAL_FROM_SNAPSHOT_TIMESTAMP) {
        Preconditions.checkArgument(
            startSnapshotTimestamp != null,
            "Invalid starting snapshot timestamp for SPECIFIC_START_SNAPSHOT_TIMESTAMP strategy: null");
        Preconditions.checkArgument(
            startSnapshotId == null,
            "Invalid starting snapshot id for SPECIFIC_START_SNAPSHOT_ID strategy: not null");
      }
      Preconditions.checkArgument(
          branch == null,
          String.format(
              "Cannot scan table using ref %s configured for streaming reader yet", branch));

      Preconditions.checkArgument(
          tag == null,
          String.format("Cannot scan table using ref %s configured for streaming reader", tag));
    }
    Preconditions.checkArgument(
        !(startTag != null && startSnapshotId() != null),
        "START_SNAPSHOT_ID and START_TAG cannot both be set.");

    Preconditions.checkArgument(
        !(endTag != null && endSnapshotId() != null),
        "END_SNAPSHOT_ID and END_TAG cannot both be set.");

    Preconditions.checkArgument(
        maxAllowedPlanningFailures >= -1,
        "Cannot set maxAllowedPlanningFailures to a negative number other than -1.");
  }
Copy from Iceberg {@link ScanContext}. only change line 115 and expand the modifier. Context
object with optional arguments for a Flink Scan.
amoro-format-mixed/amoro-mixed-flink/amoro-mixed-flink-common-iceberg-bridge/src/main/java/org/apache/iceberg/flink/source/ScanContext.java