Class WadUtils.WadEntryAccumulator

java.lang.Object
net.mtrop.doom.util.WadUtils.WadEntryAccumulator
All Implemented Interfaces:
Sizable
Enclosing class:
WadUtils

public static class WadUtils.WadEntryAccumulator extends Object implements Sizable
An accumulator for WadEntries.
Since:
2.5.0
  • Method Details

    • and

      Adds a single entry to the list. If entry is null, this does nothing.
      Parameters:
      entry - the entry to add.
      Returns:
      itself.
    • and

      public WadUtils.WadEntryAccumulator and(WadEntry... entries)
      Adds a set of entries to the list in the order that they are in the array. If entries is null, this does nothing.
      Parameters:
      entries - the entries to add.
      Returns:
      itself.
    • size

      public int size()
      Specified by:
      size in interface Sizable
      Returns:
      the amount of individual objects that this object contains.
    • isEmpty

      public boolean isEmpty()
      Description copied from interface: Sizable
      Returns if this object contains no objects. The general policy of this method is that this returns true if and only if Sizable.size() returns 0.
      Specified by:
      isEmpty in interface Sizable
      Returns:
      true if so, false otherwise.
    • get

      public WadEntry[] get()
      Gets all of the entries in this accumulator, in the order that they were added to it.
      Returns:
      an array of all of the entries accumulated so far.