java.lang.Object
io.github.palexdev.virtualizedfx.utils.Utils

public class Utils extends Object
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final io.github.palexdev.mfxcore.base.beans.range.IntegerRange
    Special instance of IntegerRange with both min and max set to -1.
  • Method Summary

    Modifier and Type
    Method
    Description
    static io.github.palexdev.mfxcore.base.beans.range.IntegerRange
    intersection(io.github.palexdev.mfxcore.base.beans.range.IntegerRange r1, io.github.palexdev.mfxcore.base.beans.range.IntegerRange r2)
    Finds the IntegerRange which is the intersection between the two given ranges.

    Methods inherited from class java.lang.Object

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

    • INVALID_RANGE

      public static final io.github.palexdev.mfxcore.base.beans.range.IntegerRange INVALID_RANGE
      Special instance of IntegerRange with both min and max set to -1. This value is in fact invalid as indexes.

      Avoids having to instantiate a new range everytime such values are needed.

  • Method Details

    • intersection

      public static io.github.palexdev.mfxcore.base.beans.range.IntegerRange intersection(io.github.palexdev.mfxcore.base.beans.range.IntegerRange r1, io.github.palexdev.mfxcore.base.beans.range.IntegerRange r2)
      Finds the IntegerRange which is the intersection between the two given ranges.

      The min is given by Math.max(r1Min, r2Min, while the max is given by Math.min(r1Max, r2Max.