org.apache.hadoop.yarn.api.protocolrecords

## Class ReservationListRequest

- java.lang.Object
- - org.apache.hadoop.yarn.api.protocolrecords.ReservationListRequest

-     @InterfaceAudience.Public
       @InterfaceStability.Unstable
      public abstract class ReservationListRequest
      extends Object

  `ReservationListRequest` captures the set of requirements the user has to list reservations.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `ReservationListRequest()`

  - ### Method Summary

    All Methods Static Methods Instance Methods Abstract Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `abstract long` | `getEndTime()` Get the end time to use to search for reservations.
    `abstract boolean` | `getIncludeResourceAllocations()` Get the boolean representing whether or not the user is requesting the full resource allocation.
    `abstract String` | `getQueue()` Get queue name to use to find reservations.
    `abstract String` | `getReservationId()` Get the reservation id to use to find a reservation.
    `abstract long` | `getStartTime()` Get the start time to use to search for reservations.
    `static ReservationListRequest` | `newInstance(String queue, String reservationId)` The `ReservationListRequest` will use the reservationId to search for reservations to list if it is provided.
    `static ReservationListRequest` | `newInstance(String queue, String reservationId, boolean includeReservationAllocations)` The `ReservationListRequest` will use the reservationId to search for reservations to list if it is provided.
    `static ReservationListRequest` | `newInstance(String queue, String reservationId, long startTime, long endTime, boolean includeReservationAllocations)` The `ReservationListRequest` will use the reservationId to search for reservations to list if it is provided.
    `abstract void` | `setEndTime(long endTime)` Set the end time to use to search for reservations.
    `abstract void` | `setIncludeResourceAllocations(boolean includeReservationAllocations)` Set the boolean representing whether or not the user is requesting the full resource allocation.
    `abstract void` | `setQueue(String queue)` Set queue name to use to find resource allocations.
    `abstract void` | `setReservationId(String reservationId)` Set the reservation id to use to find a reservation.
    `abstract void` | `setStartTime(long startTime)` Set the start time to use to search for reservations.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### ReservationListRequest

          public ReservationListRequest()

  - ### Method Detail

    - #### newInstance

          @InterfaceAudience.Public
           @InterfaceStability.Unstable
          public static ReservationListRequest newInstance(String queue,
                                                                                                                   String reservationId,
                                                                                                                   long startTime,
                                                                                                                   long endTime,
                                                                                                                   boolean includeReservationAllocations)

      The `ReservationListRequest` will use the reservationId to search for reservations to list if it is provided. Otherwise, it will select active reservations within the startTime and endTime (inclusive).
      Parameters:
        `queue` - Required. Cannot be null or empty. Refers to the reservable queue in the scheduler that was selected when creating a reservation submission `ReservationSubmissionRequest`.
        `reservationId` - Optional. String representation of `ReservationId` If provided, other fields will be ignored.
        `startTime` - Optional. If provided, only reservations that end after the startTime will be selected. This defaults to 0 if an invalid number is used.
        `endTime` - Optional. If provided, only reservations that start on or before endTime will be selected. This defaults to Long.MAX_VALUE if an invalid number is used.
        `includeReservationAllocations` - Optional. Flag that determines whether the entire reservation allocations are to be returned. Reservation allocations are subject to change in the event of re-planning as described by `ReservationDefinition`.
      Returns:
        the list of reservations via `ReservationListRequest`

    - #### newInstance

          @InterfaceAudience.Public
           @InterfaceStability.Unstable
          public static ReservationListRequest newInstance(String queue,
                                                                                                                   String reservationId,
                                                                                                                   boolean includeReservationAllocations)

      The `ReservationListRequest` will use the reservationId to search for reservations to list if it is provided. Otherwise, it will select active reservations within the startTime and endTime (inclusive).
      Parameters:
        `queue` - Required. Cannot be null or empty. Refers to the reservable queue in the scheduler that was selected when creating a reservation submission `ReservationSubmissionRequest`.
        `reservationId` - Optional. String representation of `ReservationId` If provided, other fields will be ignored.
        `includeReservationAllocations` - Optional. Flag that determines whether the entire reservation allocations are to be returned. Reservation allocations are subject to change in the event of re-planning as described by `ReservationDefinition`.
      Returns:
        the list of reservations via `ReservationListRequest`

    - #### newInstance

          @InterfaceAudience.Public
           @InterfaceStability.Unstable
          public static ReservationListRequest newInstance(String queue,
                                                                                                                   String reservationId)

      The `ReservationListRequest` will use the reservationId to search for reservations to list if it is provided. Otherwise, it will select active reservations within the startTime and endTime (inclusive).
      Parameters:
        `queue` - Required. Cannot be null or empty. Refers to the reservable queue in the scheduler that was selected when creating a reservation submission `ReservationSubmissionRequest`.
        `reservationId` - Optional. String representation of `ReservationId` If provided, other fields will be ignored.
      Returns:
        the list of reservations via `ReservationListRequest`

    - #### getQueue

          @InterfaceAudience.Public
           @InterfaceStability.Unstable
          public abstract String getQueue()

      Get queue name to use to find reservations.
      Returns:
        the queue name to use to find reservations.

    - #### setQueue

          @InterfaceAudience.Public
           @InterfaceStability.Unstable
          public abstract void setQueue(String queue)

      Set queue name to use to find resource allocations.
      Parameters:
        `queue` - Required. Cannot be null or empty.

    - #### getReservationId

          @InterfaceAudience.Public
           @InterfaceStability.Unstable
          public abstract String getReservationId()

      Get the reservation id to use to find a reservation.
      Returns:
        the reservation id of the reservation.

    - #### setReservationId

          @InterfaceAudience.Public
           @InterfaceStability.Unstable
          public abstract void setReservationId(String reservationId)

      Set the reservation id to use to find a reservation.
      Parameters:
        `reservationId` - Optional. String representation of `ReservationId` If provided, other fields will be ignored.

    - #### getStartTime

          @InterfaceAudience.Public
           @InterfaceStability.Unstable
          public abstract long getStartTime()

      Get the start time to use to search for reservations. When this is set, reservations that start before this start time are ignored.
      Returns:
        the start time to use to search for reservations.

    - #### setStartTime

          @InterfaceAudience.Public
           @InterfaceStability.Unstable
          public abstract void setStartTime(long startTime)

      Set the start time to use to search for reservations. When this is set, reservations that start before this start time are ignored.
      Parameters:
        `startTime` - Optional. If provided, only reservations that end after the startTime will be selected. This defaults to 0 if an invalid number is used.

    - #### getEndTime

          @InterfaceAudience.Public
           @InterfaceStability.Unstable
          public abstract long getEndTime()

      Get the end time to use to search for reservations. When this is set, reservations that start after this end time are ignored.
      Returns:
        the end time to use to search for reservations.

    - #### setEndTime

          @InterfaceAudience.Public
           @InterfaceStability.Unstable
          public abstract void setEndTime(long endTime)

      Set the end time to use to search for reservations. When this is set, reservations that start after this end time are ignored.
      Parameters:
        `endTime` - Optional. If provided, only reservations that start before endTime will be selected. This defaults to Long.MAX_VALUE if an invalid number is used.

    - #### getIncludeResourceAllocations

          @InterfaceAudience.Public
           @InterfaceStability.Unstable
          public abstract boolean getIncludeResourceAllocations()

      Get the boolean representing whether or not the user is requesting the full resource allocation. If this is true, the full resource allocation will be included in the response.
      Returns:
        the end time to use to search for reservations.

    - #### setIncludeResourceAllocations

          @InterfaceAudience.Public
           @InterfaceStability.Unstable
          public abstract void setIncludeResourceAllocations(boolean includeReservationAllocations)

      Set the boolean representing whether or not the user is requesting the full resource allocation. If this is true, the full resource allocation will be included in the response.
      Parameters:
        `includeReservationAllocations` - Optional. Flag that determines whether the entire list of `ResourceAllocationRequest` will be returned.

Copyright © 2022 Apache Software Foundation. All rights reserved.