Skip to content
Snippets Groups Projects
Commit 4bb1961f authored by Andreas's avatar Andreas
Browse files

ItemRegister made new method to check if register is empty

parent 8cb7251f
No related branches found
No related tags found
2 merge requests!9Added FileHandling class for ItemRegister objects, and reworked ItemRegister with new subclasses,!8Remade ItemRegister class and made FileHandling for ItemRegister-objects with tests
Pipeline #208271 failed
......@@ -51,6 +51,15 @@ public class ItemRegister<T extends Item>{
items.add(newItem);
}
/**
* Check if items is empty.
*
* @return true or false depending on if items is empty.
*/
public boolean isEmpty(){
return this.items.isEmpty();
}
/**
* Get the sum of all T´s=(Income or Expenses) in items.
*
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment