Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class Box
- {
- private int currentHeight;
- private int currentWidth;
- private int currentDepth;
- private boolean full;
- public Box(int currentHeightInt)
- {
- currentHeight = currentHeightInt;
- }
- public int getCurrentHeight()
- {
- return currentHeight;
- }
- public void setCurrentHeight(int newCurrentHeight)
- {
- currentHeight = newCurrentHeight;
- }
- public int getCurrentWidth()
- {
- return currentWidth;
- }
- public void setCurrentWidth(int newCurrentWidth)
- {
- currentWidth = newCurrentWidth;
- }
- public int getCurrentDepth()
- {
- return currentDepth;
- }
- public void setCurrentDepth(int newCurrentDepth)
- {
- currentDepth = newCurrentDepth;
- }
- public boolean getFull()
- {
- return full;
- }
- public void setFull(boolean newFull)
- {
- full = newFull;
- }
- public String toString ()
- {
- return ("Height" + "\t" + currentHeight + "\n" +
- "Width" + "\t" + currentWidth + "\n" +
- "Depth" + "\t" + currentDepth + "\n" +
- "Full?" + "\t" + full + "\n");
- }
- }
Add Comment
Please, Sign In to add comment