Advertisement
mmayoub

Item.java

Mar 3rd, 2023
122
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.51 KB | Software | 0 0
  1. package com.example.mylist;
  2.  
  3. public class Item {
  4. private String name;
  5. private int quentity;
  6.  
  7. public Item(String name, int quentity) {
  8. this.name = name;
  9. this.quentity = quentity;
  10. }
  11.  
  12. public String getName() {
  13. return name;
  14. }
  15.  
  16. public void setName(String name) {
  17. this.name = name;
  18. }
  19.  
  20. public int getQuentity() {
  21. return quentity;
  22. }
  23.  
  24. public void setQuentity(int quentity) {
  25. this.quentity = quentity;
  26. }
  27. }
  28.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement