Convenience method. author: Thomas Behr 27-03-02 @return a list with all Equipment objects this container holds; if this instance is no container, the list will be empty.
()
| 5513 | * instance is no container, the list will be empty. |
| 5514 | */ |
| 5515 | public Collection<Equipment> getContents() |
| 5516 | { |
| 5517 | |
| 5518 | return IntStream.range(0, getContainedEquipmentCount()) |
| 5519 | .mapToObj(this::getContainedEquipment).collect(Collectors.toList()); |
| 5520 | } |
| 5521 | |
| 5522 | // --------------------------- |
| 5523 | // Container Definition methods |