MCPcopy Create free account
hub / github.com/Anchals24/Low-Level-Design / ItemShelf

Class ItemShelf

StateDesignPattern/ItemShelf.java:3–32  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1package BehaviouralDesignPatterns.StateDesignPattern;
2
3public class ItemShelf {
4
5 int code;
6 Item item;
7 boolean soldOut;
8
9 public int getCode() {
10 return code;
11 }
12
13 public void setCode(int code) {
14 this.code = code;
15 }
16
17 public Item getItem() {
18 return item;
19 }
20
21 public void setItem(Item item) {
22 this.item = item;
23 }
24
25 public boolean isSoldOut() {
26 return soldOut;
27 }
28
29 public void setSoldOut(boolean soldOut) {
30 this.soldOut = soldOut;
31 }
32}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected