|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectPandora.ProofItem
Pandora.ProofBox
public class ProofBox
Implements a box in a proof.
Extends ProofItem, so a proof is made up of a list of ProofItems.
Contains a linked list of ProofItems, which make up the lines of the proof in the box.
Field Summary | |
---|---|
int |
skolem
|
Constructor Summary | |
---|---|
ProofBox(ProofLine goal,
ProofWindow parentWindow,
ProofBox parentBox)
Constructs a ProofBox (with Goal). |
|
ProofBox(ProofWindow parentWindow)
Constructs a ProofBox (Outer). |
|
ProofBox(ProofWindow parentWindow,
ProofBox parentBox)
Constructs a ProofBox. |
Method Summary | |
---|---|
void |
addItem(int index,
ProofItem item)
Adds ProofItem to specified position in LinkedList of ProofItems. |
void |
addItem(ProofItem item)
Adds ProofItem to the LinkedList of ProofItems in the ProofBox. |
void |
addSkolems(ProofBox parBox,
PanSignature temp)
|
void |
addToSignature(java.util.List<Atom> newAtoms)
Adds the given list of Atoms to the signature of the ProofBox. |
void |
cleanup()
Removes the empty line before a goal line when that goal has become proved but there are still goals remaining in the proof. |
void |
deselectAll()
Used to deselect the items once a rule has been executed or the rule failed to execute. |
javax.swing.JPanel |
display()
Returns the ProofBox within a JPanel. |
boolean |
getDisplayBorder()
Returns true is the box is displayed. |
boolean |
getDisplayItems()
Returns true if box's ProofItems are not hidden, otherwise false. |
int |
getIndex(ProofItem current)
Returns the index of a given ProofItem |
PanSignature |
getMainSignature()
|
ProofBox |
getNextBox()
Returns the next ProofBox in the list. |
ProofBox |
getOlderSiblingBox()
Returns the ProofBox that references this ProofBox as its nextBox. |
java.util.List<ProofItem> |
getProofItems()
Returns the list of ProofItems contained in the box. |
PanSignature |
getSignature()
Returns the signature of the ProofBox. |
boolean |
hasNextBox()
A ProofBox item in a proof may be a list of ProofBoxes. |
boolean |
isProved()
|
void |
mouseClicked(java.awt.event.MouseEvent e)
Responds to a ProofBox with a mouse listener being clicked. |
ProofItem |
next(ProofItem current)
Returns the next ProofItem in the ProofItems list |
int |
recalculateLineNum(int line)
Recalculates the line numbers within the ProofBox. |
void |
regenerate(ProofBox outsideBox,
ProofWindow parentWindow)
Copies (this) ProofBox to the given outsideBox. |
void |
removeItem(int index)
Removes the specified item from the list of ProofItems |
void |
setBoxStarted(boolean option)
Sets if the box has been started or not |
void |
setDashedBox(boolean option)
Controls the appearance of the ProofBox. |
void |
setDisplayBorder(boolean option)
Used to set the display options of the ProofBox. |
void |
setDisplayItems(boolean option)
Controls if the content of the ProofBox should be displayed. |
ProofBox |
setNextBox()
Creates a new ProofBox to follow the current ProofBox and returns this new sibling ProofBox. |
void |
setOlderSiblingBox(ProofBox sibling)
Sets the olderSiblingBox of this ProofBox as the ProofBox that refernces this ProofBox as its nextBox. |
Methods inherited from class Pandora.ProofItem |
---|
displayColour, getParentBox, getParentWindow, mouseEntered, mouseExited, mousePressed, mouseReleased, setParentBox |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface java.awt.event.MouseListener |
---|
mouseEntered, mouseExited, mousePressed, mouseReleased |
Field Detail |
---|
public int skolem
Constructor Detail |
---|
public ProofBox(ProofWindow parentWindow)
parentWindow
- The ProofWindow that the box is inside.public ProofBox(ProofWindow parentWindow, ProofBox parentBox)
parentWindow
- The ProofWindow that the box is inside.parentBox
- The outer ProofBox that contains this ProofBox.public ProofBox(ProofLine goal, ProofWindow parentWindow, ProofBox parentBox)
goal
- The goal of the ProofBoxparentWindow
- The ProofWindow that the box is inside.parentBox
- The outer ProofBox that contains this ProofBox.Method Detail |
---|
public ProofBox getNextBox()
public ProofBox setNextBox()
public boolean hasNextBox()
public ProofBox getOlderSiblingBox()
public void setOlderSiblingBox(ProofBox sibling)
public void setBoxStarted(boolean option)
public boolean isProved()
public boolean getDisplayBorder()
public void setDisplayBorder(boolean option)
option
- Box is displayed when true, otherwise hiddenpublic boolean getDisplayItems()
public void setDisplayItems(boolean option)
option
- Box is displayed when true, otherwise hiddenpublic void setDashedBox(boolean option)
option
- A dashed line ProofBox is displayed when truepublic java.util.List<ProofItem> getProofItems()
public int recalculateLineNum(int line)
recalculateLineNum
in class ProofItem
line
- The value of the first line in the ProofBoxpublic ProofItem next(ProofItem current)
current
- current ProofItempublic int getIndex(ProofItem current)
current
- current ProofItempublic void addItem(ProofItem item)
item
- ProofItem to be addedpublic void addItem(int index, ProofItem item)
index
- Position to additem
- ProofItem to be addedpublic void removeItem(int index)
index
- Index of ProofItem to be removedpublic void addSkolems(ProofBox parBox, PanSignature temp)
public void addToSignature(java.util.List<Atom> newAtoms)
newAtoms
- the atoms to be added to the signaturepublic PanSignature getSignature()
public PanSignature getMainSignature()
public void deselectAll()
public javax.swing.JPanel display()
display
in class ProofItem
public void mouseClicked(java.awt.event.MouseEvent e)
mouseClicked
in interface java.awt.event.MouseListener
mouseClicked
in class ProofItem
e
- the object with a mouse listener that was clickedpublic void cleanup()
public void regenerate(ProofBox outsideBox, ProofWindow parentWindow)
outsideBox
- destination of regenerated ProofBoxparentWindow
- window which the current and new ProofBox belong to
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |