Class SearchPanel

All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible

public class SearchPanel extends JPanel
Panel used to search documents in an archive.
Matteo Caruso - LogicalDOC
See Also:
  • Constructor Details

  • Method Details

    • getInstance

      public static SearchPanel getInstance(ArchiveViewer viewer)
      Get a new instance of SearchPanel
      viewer - the application instance
      the seach panel instance
    • clean

      public static void clean()
      Clean all the criteria of the current instance of SearchPanel
    • getCriteria

      public List<Criterion> getCriteria()
    • checkCriterion

      public boolean checkCriterion(Criterion criterion)
      Method similar to 'isNull' method of the 'Criterion' class. This method is necessary because for the template field is used a string value and for the date field is used a string value. If is used also to retrieves all the input text format errors
      criterion - The criterion to check
      true if the criterion is valid, false if it is not valid
    • getColumnName

      public String getColumnName(Criterion criterion)
      Method similar to 'getColumnName' method of the 'Criterion' class. This method is necessary because for the template field is used the 'ld_templatename' column
      criterion - The evaluated criterion
      the column name
    • getSearchErrors

      public String getSearchErrors()
    • removeLine

      public void removeLine(SearchLine searchLine)
      Removing a Search Line, this method removes also the associated criterion from the criterion list. Then the Search Panel is cleaned and reloaded
      searchLine - the criterion line
    • getLabelFromArray

      public String getLabelFromArray(Item[] items, String value)
      Useful method used to get the Label string of a Item with the given Value inside the given Item list
      items - the list of Items in which is carried the research
      value - the Item's value
      the label
    • updateFieldsList

      public void updateFieldsList(boolean updateOperatorsAndValues)
      This method updates the list of available fields.
      updateOperatorsAndValues - If true also the operators and the values string are updated.
    • updateOperatorsList

      public void updateOperatorsList()
      This method updates the list of operators values. Then also the available fields list is updated
    • getSearchLines

      public static List<SearchLine> getSearchLines()
    • getLinesPanel

      public JPanel getLinesPanel()
    • getSelectedTemplate

      public String getSelectedTemplate()