Package mgui.interfaces.io
Class InterfaceFile
java.lang.Object
mgui.interfaces.io.InterfaceFile
- All Implemented Interfaces:
InterfaceObject,NamedObject,TreeObject,CleanableObject
public class InterfaceFile extends java.lang.Object implements InterfaceObject
-
Field Summary
-
Constructor Summary
Constructors Constructor Description InterfaceFile(java.io.File file)InterfaceFile(java.io.File file, javax.swing.filechooser.FileFilter filter) -
Method Summary
Modifier and Type Method Description voidclean()Instructs this object to search its members for any object which has been destroyed, and release the pointer to it.voiddestroy()Destroy this object (prepare it to be removed from memory)static javax.swing.filechooser.FileFiltergetDirFilter()java.io.FilegetFile()javax.swing.filechooser.FileFiltergetFileFilter()static javax.swing.filechooser.FileFiltergetFilter(java.lang.String[] ext, java.lang.String description)java.lang.StringgetName()Gets the name for this object.java.lang.StringgetTreeLabel()Returns the label text to appear in a tree node.booleanisDestroyed()Test whether this object has been destroyedInterfaceTreeNodeissueTreeNode()Issues a newInterfaceTreeNodefor this object.voidsetFile(java.io.File file)voidsetFileFilter(javax.swing.filechooser.FileFilter filter)voidsetName(java.lang.String name)Sets the name for this object.voidsetTreeNode(InterfaceTreeNode node)Sets the children for this node'sInterfaceTreeNode.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Field Details
-
file
protected java.io.File file -
filter
protected javax.swing.filechooser.FileFilter filter -
destroyed
protected boolean destroyed
-
-
Constructor Details
-
InterfaceFile
public InterfaceFile(java.io.File file) -
InterfaceFile
public InterfaceFile(java.io.File file, javax.swing.filechooser.FileFilter filter)
-
-
Method Details
-
setFile
public void setFile(java.io.File file) -
getFile
public java.io.File getFile() -
setFileFilter
public void setFileFilter(javax.swing.filechooser.FileFilter filter) -
getFileFilter
public javax.swing.filechooser.FileFilter getFileFilter() -
clean
public void clean()Description copied from interface:CleanableObjectInstructs this object to search its members for any object which has been destroyed, and release the pointer to it.- Specified by:
cleanin interfaceCleanableObject
-
destroy
public void destroy()Description copied from interface:InterfaceObjectDestroy this object (prepare it to be removed from memory)- Specified by:
destroyin interfaceInterfaceObject
-
getName
public java.lang.String getName()Description copied from interface:NamedObjectGets the name for this object.- Specified by:
getNamein interfaceNamedObject- Returns:
-
isDestroyed
public boolean isDestroyed()Description copied from interface:InterfaceObjectTest whether this object has been destroyed- Specified by:
isDestroyedin interfaceInterfaceObject- Returns:
-
setName
public void setName(java.lang.String name)Description copied from interface:NamedObjectSets the name for this object.- Specified by:
setNamein interfaceNamedObject
-
getTreeLabel
public java.lang.String getTreeLabel()Description copied from interface:TreeObjectReturns the label text to appear in a tree node.- Specified by:
getTreeLabelin interfaceTreeObject- Returns:
-
issueTreeNode
Description copied from interface:TreeObjectIssues a newInterfaceTreeNodefor this object. The object is responsible for maintaining, updating, and destroying the tree nodes it issues, or notifying containers -- i.e., parent trees -- of changes which require the tree nodes to be modified or destroyed.- Specified by:
issueTreeNodein interfaceTreeObject- Returns:
-
setTreeNode
Description copied from interface:TreeObjectSets the children for this node'sInterfaceTreeNode.- Specified by:
setTreeNodein interfaceTreeObject
-
getDirFilter
public static javax.swing.filechooser.FileFilter getDirFilter() -
getFilter
public static javax.swing.filechooser.FileFilter getFilter(java.lang.String[] ext, java.lang.String description)
-