Class SpallocAPI.CreateDescriptor

java.lang.Object
uk.ac.manchester.spinnaker.alloc.allocator.SpallocAPI.CreateDescriptor
Direct Known Subclasses:
SpallocAPI.CreateDimensions, SpallocAPI.CreateNumBoards, SpallocAPI.HasBoardCoords
Enclosing interface:
SpallocAPI

public abstract static class SpallocAPI.CreateDescriptor extends Object
Describes what sort of request to create a job this is.
See Also:
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    final @jakarta.validation.constraints.PositiveOrZero(message="maxDeadBoards must not be negative") int
    The maximum number of dead boards tolerated in the allocation.
  • Method Summary

    Modifier and Type
    Method
    Description
    abstract int
    Get the area.
    final <T> T
    Apply a visitor to this descriptor.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • maxDead

      @PositiveOrZero(message="maxDeadBoards must not be negative") public final @jakarta.validation.constraints.PositiveOrZero(message="maxDeadBoards must not be negative") int maxDead
      The maximum number of dead boards tolerated in the allocation. Ignored when asking for a single board.
  • Method Details

    • visit

      public final <T> T visit(SpallocAPI.CreateVisitor<T> visitor)
      Apply a visitor to this descriptor.
      Type Parameters:
      T - The type of the result of the visiting.
      Parameters:
      visitor - The visitor to apply.
      Returns:
      The result computed by the visitor.
    • getArea

      public abstract int getArea()
      Get the area. The area is the number of boards required.
      Returns:
      The number of boards requested by the job.