Class JDPSearchResults
java.lang.Object
|
+----java.awt.Component
|
+----java.awt.Container
|
+----java.awt.Panel
|
+----JDPSearchResults
- public class JDPSearchResults
- extends Panel
Class JDPSearchResults represents a tree structure or a list that contains
key elements of a database table(s) that allow subsequent selection for loading
other databound classes such as grids, columns or charts.
-
JDPSearchResults(JDPUser)
- Creates a Search Results panel.
-
JDPSearchResults(JDPUser, boolean, JDPJagg, boolean, String, int[], String, String[], String[], String[], String, boolean, String)
- Creates a Search Results panel.
-
JDPSearchResults(JDPUser, boolean, JDPJagg, boolean, String, String[], String, String[], String[], String[], String, boolean, String)
- Creates a Search Results panel.
-
JDPSearchResults(JDPUser, Container, boolean, JDPJagg, boolean, String, String[], String, String[], String[], String[], String, boolean, String)
- Creates a Search Results panel.
-
JDPSearchResults(JDPUser, JDPJagg, boolean, String, String, String[], String[], String[], String, boolean, String)
- Creates a Search Results panel.
-
JDPSearchResults(JDPUser, Panel, boolean, JDPJagg, boolean, String, String[], String, String[], String[], String[], String, boolean, String)
- Creates a Search Results panel.
-
clearList()
- Clear all the entries from the list or the tree
-
clearList(String)
- Clear all the entries from the tree and set the root name
-
getAllowMultSel()
- Set the multiple selection flag if this is a list and not a tree
-
getBackground()
-
-
getFont()
-
-
getForeground()
-
-
getListHandle()
- Get the handle to the list component that is being used by this Result List.
-
getMinHeight()
- Get mimimum height of this panel
-
getMinWidth()
- Get mimimum width of this panel
-
getSelectedBranch()
- Get the branch names of the currently selected branch.
-
getSelectedIndex()
- Get the currently selected index for the list or the tree.
-
getSelectedKey()
- Get the currently selected database key values for the list or the tree.
-
getTotalEntries()
- Get the total entries currently displayed.
-
getTreeHandle()
- Get the handle to the tree component that is being used by this Result List.
-
handleEvent(Event)
-
-
loadList()
- Load the list or tree using the current settings.
-
resetSelections()
- Reset the selections.
-
setAllowMultSel(boolean)
- Set the multiple selection flag if this is a list and not a tree
-
setBackground(Color)
-
-
setDisplayChoice(String[])
- Set the new display choice column names
-
setFont(Font)
-
-
setForeground(Color)
-
-
setFromWhereClause(String)
- Set the new from/where clause
-
setIcon(int)
- Set the icon for this list
-
setIcons(int[])
- Set the icons for this tree
-
setListEvents(boolean)
- Set the the flag to cause tree branch selections to trigger a list selected
event.
-
setMinHeight(int)
- Set mimimum height of this panel
-
setMinWidth(int)
- Set mimimum width of this panel
-
setSelectedKey(String[])
- Select the branch in the Result List based on the key.
-
setSortChoice(String[])
- Set the new sort choice column names
-
setTableKey(String)
- Set the new table key clause
JDPSearchResults
public JDPSearchResults(JDPUser user,
Container targetPanel,
boolean useTreeClass,
JDPJagg jaggSQL,
boolean pallowMultSel,
String pselectFields,
String psdisplayFields[],
String pfromWhereClause,
String psortChoiceText[],
String psortChoice[],
String pdisplayChoice[],
String pinitChoice,
boolean pdisplayCount,
String countText)
- Creates a Search Results panel.
- Parameters:
- JDPUser - the global user parameter used to pass handles in JDP.
- targetPanel - the parent panel that this one will be added to.
- useTreeClass - specifies whether this is a tree structure or a list.
- JDPJagg - a handle to an instance of JDPJagg. DSN and CSTR must already be intialized.
- pallowMultSel - for lists specifies whether multiple selection is allowed
- pselectFields - the database column names to retrieve to load the tree or list
- psdisplayFields - the database column name to sort the entries by
- fromWhereClause - the from/where clause to use when selecting rows from the table
- psortChoiceText - the values for the sort choice pulldown
- psortChoice - the actual column names for the sort choice pulldown
- pdisplayChoice - the display choice values
- pinitChoice - the initial choice for the sort choice pulldown
- pdisplayCount - the display a result count flag
- countText - the text for the row count
JDPSearchResults
public JDPSearchResults(JDPUser user,
Panel targetPanel,
boolean useTreeClass,
JDPJagg jaggSQL,
boolean pallowMultSel,
String pselectFields,
String psdisplayFields[],
String pfromWhereClause,
String psortChoiceText[],
String psortChoice[],
String pdisplayChoice[],
String pinitChoice,
boolean pdisplayCount,
String countText)
- Creates a Search Results panel.
- Parameters:
- JDPUser - the global user parameter used to pass handles in JDP.
- targetPanel - the parent panel that this one will be added to.
- useTreeClass - specifies whether this is a tree structure or a list.
- JDPJagg - a handle to an instance of JDPJagg. DSN and CSTR must already be intialized.
- pallowMultSel - for lists specifies whether multiple selection is allowed
- pselectFields - the database column names to retrieve to load the tree or list
- psdisplayFields - the database column name to sort the entries by
- fromWhereClause - the from/where clause to use when selecting rows from the table
- psortChoiceText - the values for the sort choice pulldown
- psortChoice - the actual column names for the sort choice pulldown
- pdisplayChoice - the display choice values
- pinitChoice - the initial choice for the sort choice pulldown
- pdisplayCount - the display a result count flag
- countText - the text for the row count
JDPSearchResults
public JDPSearchResults(JDPUser user,
boolean useTreeClass,
JDPJagg jaggSQL,
boolean pallowMultSel,
String pselectFields,
String psdisplayFields[],
String pfromWhereClause,
String psortChoiceText[],
String psortChoice[],
String pdisplayChoice[],
String pinitChoice,
boolean pdisplayCount,
String countText)
- Creates a Search Results panel.
- Parameters:
- JDPUser - the global user parameter used to pass handles in JDP.
- useTreeClass - specifies whether this is a tree structure or a list.
- JDPJagg - a handle to an instance of JDPJagg. DSN and CSTR must already be intialized.
- pallowMultSel - for lists specifies whether multiple selection is allowed
- pselectFields - the database column names to retrieve to load the tree or list
- psdisplayFields - the database column name to sort the entries by
- fromWhereClause - the from/where clause to use when selecting rows from the table
- psortChoiceText - the values for the sort choice pulldown
- psortChoice - the actual column names for the sort choice pulldown
- pdisplayChoice - the display choice values
- pinitChoice - the initial choice for the sort choice pulldown
- pdisplayCount - the display a result count flag
- countText - the text for the row count
JDPSearchResults
public JDPSearchResults(JDPUser user,
boolean useTreeClass,
JDPJagg jaggSQL,
boolean pallowMultSel,
String pselectFields,
int pdisplayFields[],
String pfromWhereClause,
String psortChoiceText[],
String psortChoice[],
String pdisplayChoice[],
String pinitChoice,
boolean pdisplayCount,
String countText)
- Creates a Search Results panel.
- Parameters:
- JDPUser - the global user parameter used to pass handles in JDP.
- useTreeClass - specifies whether this is a tree structure or a list.
- JDPJagg - a handle to an instance of JDPJagg. DSN and CSTR must already be intialized.
- pallowMultSel - for lists specifies whether multiple selection is allowed
- pselectFields - the database column names to retrieve to load the tree or list
- pdisplayFields - the field indexes in pselectFields to order by
- fromWhereClause - the from/where clause to use when selecting rows from the table
- psortChoiceText - the values for the sort choice pulldown
- psortChoice - the actual column names for the sort choice pulldown
- pdisplayChoice - the display choice values
- pinitChoice - the initial choice for the sort choice pulldown
- pdisplayCount - the display a result count flag
- countText - the text for the row count
JDPSearchResults
public JDPSearchResults(JDPUser user,
JDPJagg jaggSQL,
boolean pallowMultSel,
String pselectFields,
String pfromWhereClause,
String psortChoiceText[],
String psortChoice[],
String pdisplayChoice[],
String pinitChoice,
boolean pdisplayCount,
String countText)
- Creates a Search Results panel.
- Parameters:
- JDPUser - the global user parameter used to pass handles in JDP.
- JDPJagg - a handle to an instance of JDPJagg. DSN and CSTR must already be intialized.
- pallowMultSel - for lists specifies whether multiple selection is allowed
- pselectFields - the database column names to retrieve to load the tree or list
- fromWhereClause - the from/where clause to use when selecting rows from the table
- psortChoiceText - the values for the sort choice pulldown
- psortChoice - the actual column names for the sort choice pulldown
- pdisplayChoice - the display choice values
- pinitChoice - the initial choice for the sort choice pulldown
- pdisplayCount - the display a result count flag
- countText - the text for the row count
JDPSearchResults
public JDPSearchResults(JDPUser user)
- Creates a Search Results panel.
- Parameters:
- JDPUser - the global user parameter used to pass handles in JDP.
getTotalEntries
public int getTotalEntries()
- Get the total entries currently displayed.
- Returns:
- the total entries currently displayed.
setBackground
public void setBackground(Color plistBgColor)
- Overrides:
- setBackground in class Component
getBackground
public Color getBackground()
- Overrides:
- getBackground in class Component
setForeground
public void setForeground(Color plistFgColor)
- Overrides:
- setForeground in class Component
getForeground
public Color getForeground()
- Overrides:
- getForeground in class Component
setFont
public void setFont(Font thisFont)
- Overrides:
- setFont in class Component
getFont
public Font getFont()
- Overrides:
- getFont in class Component
setMinWidth
public void setMinWidth(int width)
- Set mimimum width of this panel
- Parameters:
- width - the new minimum width of this panel
getMinWidth
public int getMinWidth()
- Get mimimum width of this panel
- Returns:
- width the new minimum width of this panel
setMinHeight
public void setMinHeight(int height)
- Set mimimum height of this panel
- Parameters:
- height - the new minimum height of this panel
getMinHeight
public int getMinHeight()
- Get mimimum height of this panel
- Returns:
- width the new minimum height of this panel
clearList
public void clearList()
- Clear all the entries from the list or the tree
clearList
public void clearList(String name)
- Clear all the entries from the tree and set the root name
- Parameters:
- name - new root name for the tree
resetSelections
public void resetSelections()
- Reset the selections.
setFromWhereClause
public void setFromWhereClause(String clause)
- Set the new from/where clause
- Parameters:
- fromWhereClause - the new from/where clause for the loadList method.
setTableKey
public void setTableKey(String clause)
- Set the new table key clause
- Parameters:
- pselectFields - the new table key clause for the loadList method.
setSortChoice
public void setSortChoice(String sort[])
- Set the new sort choice column names
- Parameters:
- psortChoice - the new sort choice column names for the loadList method.
setDisplayChoice
public void setDisplayChoice(String display[])
- Set the new display choice column names
- Parameters:
- pdisplayChoice - the new display choice column names for the loadList method.
setAllowMultSel
public void setAllowMultSel(boolean pallowMultSel)
- Set the multiple selection flag if this is a list and not a tree
- Parameters:
- pallowMultSel - the new value of the multiple selection flag.
getAllowMultSel
public boolean getAllowMultSel()
- Set the multiple selection flag if this is a list and not a tree
- Parameters:
- pallowMultSel - the new value of the multiple selection flag.
setListEvents
public void setListEvents(boolean listEvents)
- Set the the flag to cause tree branch selections to trigger a list selected
event. By default this class will only kick an event if the lowest level of
a tree branch is selected. Changing this flag allows upper branches to also
kick an event.
- Parameters:
- listEvents - the new value of the list events flag.
loadList
public void loadList()
- Load the list or tree using the current settings.
setIcons
public void setIcons(int icons[])
- Set the icons for this tree
- Parameters:
- icons - the icons for the various branch levels of the tree.
setIcon
public void setIcon(int icon)
- Set the icon for this list
- Parameters:
- icon - the icon for the entries in the list.
getTreeHandle
public JDPTreePicker getTreeHandle()
- Get the handle to the tree component that is being used by this Result List.
- Returns:
- the handle to the tree component that is being used by this Result List.
getListHandle
public JDPList getListHandle()
- Get the handle to the list component that is being used by this Result List.
- Returns:
- the handle to the list component that is being used by this Result List.
getSelectedIndex
public int getSelectedIndex()
- Get the currently selected index for the list or the tree.
- Returns:
- the currently selected index for the list or the tree.
getSelectedBranch
public String[] getSelectedBranch()
- Get the branch names of the currently selected branch.
- Returns:
- the branch names of the currently selected branch.
setSelectedKey
public boolean setSelectedKey(String key[])
- Select the branch in the Result List based on the key.
- Parameters:
- the - key of the branch to select.
- Returns:
- the whether the key was found in the result list.
getSelectedKey
public String[] getSelectedKey()
- Get the currently selected database key values for the list or the tree.
- Returns:
- the currently selected key values for the list or the tree.
handleEvent
public boolean handleEvent(Event e)
- Overrides:
- handleEvent in class Component