|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.sun.webui.jsf.model.FileChooserModel
public class FileChooserModel
Constructor Summary | |
---|---|
FileChooserModel()
Creates a new instance of FileChooserModel |
Method Summary | |
---|---|
boolean |
canRead(java.lang.String resourceName)
This methods checks if the resource path in question can be accessed by the user trying to select or view it. |
boolean |
canWrite(java.lang.String resourceName)
This methods checks if the resource path in question can be accessed for writes by the user. |
java.lang.String |
getAbsoluteRoot()
Returns the root value of the file system in question. |
java.lang.String |
getCurrentDir()
This method is called to get the current directory of the resuource list being displayed in the filechooser's listbox If the current directory has not been set, root directory is returned by calling getAbsoluteRoot() . |
java.lang.String |
getDelimiterChar()
|
java.lang.String |
getEscapeChar()
|
java.lang.String |
getFilterValue()
Return the filter String currently in use. |
com.sun.webui.jsf.model.ResourceItem[] |
getFolderContent(java.lang.String folder,
boolean disableFiles,
boolean disableFolders)
Returns the list of files in the directory represented by the folder parameter. |
java.lang.String |
getParentFolder()
Return the parent folder of the value of getCurrentDir . |
com.sun.webui.jsf.model.ResourceItem |
getResourceItem(java.lang.String itemKey)
Given a ResourceItem key return the ResourceItem. |
java.lang.String[] |
getRoots()
Return all available roots. |
java.lang.Object[] |
getSelectedContent(java.lang.String[] content,
boolean selectFolders)
Return a File[] of the selections in content validating the the entries. |
java.lang.String |
getSeparatorString()
Return the separator String for this resource system. |
java.lang.String |
getServerName()
Get the Server namefrom where the resources are being loaded. |
java.lang.String |
getSortValue()
Return the sort field that is currently active. |
boolean |
isFolderType(java.lang.String path)
Returns true if the supplied absolute path is a folder type. |
void |
setAbsoluteRoot(java.lang.String absRoot)
Sets the root value of the resource system in question. |
void |
setCurrentDir(java.lang.String dir)
This method is called to set the current directory of the resuource list that would be displayed in the next display cycle. |
void |
setFilterValue(java.lang.String filterValue)
Set the filter String entered by the user in the Filter text field. |
void |
setServerName(java.lang.String serverName)
Set the server name from where the resources are being loaded. |
void |
setSortValue(java.lang.String sortValue)
Set the sort field chosen by the user from the drop down menu. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FileChooserModel()
Method Detail |
---|
public java.lang.String getAbsoluteRoot()
getAbsoluteRoot
in interface com.sun.webui.jsf.model.ResourceModel
public java.lang.String[] getRoots()
getRoots
in interface com.sun.webui.jsf.model.ResourceModel
public void setAbsoluteRoot(java.lang.String absRoot)
setAbsoluteRoot
in interface com.sun.webui.jsf.model.ResourceModel
absRoot
- - the value to be used as the root of this resource systempublic java.lang.String getSeparatorString()
getSeparatorString
in interface com.sun.webui.jsf.model.ResourceModel
public java.lang.String getServerName()
getServerName
in interface com.sun.webui.jsf.model.ResourceModel
public void setServerName(java.lang.String serverName)
setServerName
in interface com.sun.webui.jsf.model.ResourceModel
serverName
- - the server name to be setpublic java.lang.String getFilterValue()
getFilterValue
in interface com.sun.webui.jsf.model.ResourceModel
public void setFilterValue(java.lang.String filterValue)
setFilterValue
in interface com.sun.webui.jsf.model.ResourceModel
filterValue
- - the filter string to be used subsequently.public java.lang.String getSortValue()
getSortValue
in interface com.sun.webui.jsf.model.ResourceModel
public void setSortValue(java.lang.String sortValue)
setSortValue
in interface com.sun.webui.jsf.model.ResourceModel
sortValue
- - string representing sortValue selected by the user.public java.lang.String getCurrentDir()
getAbsoluteRoot()
.
getCurrentDir
in interface com.sun.webui.jsf.model.ResourceModel
public void setCurrentDir(java.lang.String dir) throws ResourceModelException
setCurrentDir
in interface com.sun.webui.jsf.model.ResourceModel
dir
- - the value to be set the new current root node.
ResourceModelException
public com.sun.webui.jsf.model.ResourceItem[] getFolderContent(java.lang.String folder, boolean disableFiles, boolean disableFolders)
folder
parameter. If folder
is null
the contents of folder returned by getCurrentDir
are returned. This method returns an Array of ResourecItem objects
getFolderContent
in interface com.sun.webui.jsf.model.ResourceModel
public com.sun.webui.jsf.model.ResourceItem getResourceItem(java.lang.String itemKey)
getResourceItem
in interface com.sun.webui.jsf.model.ResourceModel
itemKey
- the resource item key which is the same as the value
of the Option element in the listbox.
public boolean isFolderType(java.lang.String path)
isFolderType
in interface com.sun.webui.jsf.model.ResourceModel
path
- - the absolute path to the resource
public boolean canRead(java.lang.String resourceName)
canRead
in interface com.sun.webui.jsf.model.ResourceModel
resourceName
- - the resource name to check for read access
public boolean canWrite(java.lang.String resourceName)
canWrite
in interface com.sun.webui.jsf.model.ResourceModel
resourceName
- - the resource name to check for write access
public java.lang.String getParentFolder()
getCurrentDir
.
If the current directory does not have a parent
null is returned.
getParentFolder
in interface com.sun.webui.jsf.model.ResourceModel
public java.lang.String getEscapeChar()
getEscapeChar
in interface com.sun.webui.jsf.model.ResourceModel
public java.lang.String getDelimiterChar()
getDelimiterChar
in interface com.sun.webui.jsf.model.ResourceModel
public java.lang.Object[] getSelectedContent(java.lang.String[] content, boolean selectFolders) throws ResourceModelException
getSelectedContent
in interface com.sun.webui.jsf.model.ResourceModel
ResourceModelException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |