Autopsy  4.19.3
Graphical digital forensics platform for The Sleuth Kit and other tools.
AbstractDiscoveryFilterPanel.java
Go to the documentation of this file.
1 /*
2  * Autopsy
3  *
4  * Copyright 2020 Basis Technology Corp.
5  * Contact: carrier <at> sleuthkit <dot> org
6  *
7  * Licensed under the Apache License, Version 2.0 (the "License");
8  * you may not use this file except in compliance with the License.
9  * You may obtain a copy of the License at
10  *
11  * http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing, software
14  * distributed under the License is distributed on an "AS IS" BASIS,
15  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16  * See the License for the specific language governing permissions and
17  * limitations under the License.
18  */
19 package org.sleuthkit.autopsy.discovery.ui;
20 
22 import java.awt.event.ActionListener;
23 import java.util.List;
24 import javax.swing.JCheckBox;
25 import javax.swing.JLabel;
26 import javax.swing.event.ListSelectionListener;
28 
32 abstract class AbstractDiscoveryFilterPanel extends javax.swing.JPanel {
33 
34  private static final long serialVersionUID = 1L;
35 
45  @ThreadConfined(type = ThreadConfined.ThreadType.AWT)
46  abstract void configurePanel(boolean selected, List<?> selectedItems);
47 
53  @ThreadConfined(type = ThreadConfined.ThreadType.AWT)
54  abstract JCheckBox getCheckbox();
55 
61  @ThreadConfined(type = ThreadConfined.ThreadType.AWT)
62  abstract void addListSelectionListener(ListSelectionListener listener);
63 
70  @ThreadConfined(type = ThreadConfined.ThreadType.AWT)
71  abstract JLabel getAdditionalLabel();
72 
79  @ThreadConfined(type = ThreadConfined.ThreadType.AWT)
80  abstract String checkForError();
81 
89  @ThreadConfined(type = ThreadConfined.ThreadType.AWT)
90  void addListeners(ActionListener actionListener, ListSelectionListener listListener) {
91  if (getCheckbox() != null) {
92  getCheckbox().addActionListener(actionListener);
93  }
94  if (hasPanel() == true) {
95  addListSelectionListener(listListener);
96  }
97  }
98 
105  @ThreadConfined(type = ThreadConfined.ThreadType.AWT)
106  abstract AbstractFilter getFilter();
107 
111  abstract boolean isFilterSupported();
112 
119  boolean hasPanel() {
120  return true;
121  }
122 
123 }

Copyright © 2012-2022 Basis Technology. Generated on: Tue Jun 27 2023
This work is licensed under a Creative Commons Attribution-Share Alike 3.0 United States License.