19 package org.sleuthkit.autopsy.modules.interestingitems;
 
   21 import org.openide.DialogDisplayer;
 
   22 import org.openide.NotifyDescriptor;
 
   23 import org.openide.util.NbBundle;
 
   32     @NbBundle.Messages({
"FilesSetPanel.ingest.title=File Ingest Filter", 
"FilesSetPanel.ingest.createNewFilter=Create/edit file ingest filters...", 
"FilesSetPanel.ingest.messages.filtersMustBeNamed=File ingest filters must be named."})
 
   51             mustBeNamedErrorText = NbBundle.getMessage(
FilesSetPanel.class, 
"FilesSetPanel.ingest.messages.filtersMustBeNamed");
 
   52             org.openide.awt.Mnemonics.setLocalizedText(
nameLabel, 
org.openide.util.NbBundle.getMessage(
FilesSetPanel.class, 
"FilesSetPanel.ingest.nameLabel.text")); 
 
   54             mustBeNamedErrorText = NbBundle.getMessage(FilesSetPanel.class, 
"FilesSetPanel.interesting.messages.filesSetsMustBeNamed");
 
   64     FilesSetPanel(FilesSet filesSet, PANEL_TYPE panelType) {
 
   66         if (panelType == PANEL_TYPE.FILE_INGEST_FILTERS) {
 
   68             mustBeNamedErrorText = NbBundle.getMessage(FilesSetPanel.class, 
"FilesSetPanel.ingest.messages.filtersMustBeNamed");
 
   71             mustBeNamedErrorText = NbBundle.getMessage(FilesSetPanel.class, 
"FilesSetPanel.interesting.messages.filesSetsMustBeNamed");
 
   86     boolean isValidDefinition() {
 
   88             NotifyDescriptor notifyDesc = 
new NotifyDescriptor.Message(
 
   90                     NotifyDescriptor.WARNING_MESSAGE);
 
   91             DialogDisplayer.getDefault().notify(notifyDesc);
 
   96             for (FilesSet filesSet : FilesSetsManager.getStandardFileIngestFilters()) {
 
   97                 if (this.
nameTextField.getText().equals(filesSet.getName())) {
 
   98                     NotifyDescriptor notifyDesc = 
new NotifyDescriptor.Message(
 
   99                             NbBundle.getMessage(FilesSetPanel.class, 
"FilesSetPanel.messages.filesSetsReservedName"),
 
  100                             NotifyDescriptor.WARNING_MESSAGE);
 
  101                     DialogDisplayer.getDefault().notify(notifyDesc);
 
  106                 NotifyDescriptor notifyDesc = 
new NotifyDescriptor.Message(
 
  107                         NbBundle.getMessage(FilesSetPanel.class, 
"FilesSetPanel.messages.filesSetsReservedName"),
 
  108                         NotifyDescriptor.WARNING_MESSAGE);
 
  109                 DialogDisplayer.getDefault().notify(notifyDesc);
 
  121     String getFilesSetName() {
 
  132     String getFilesSetDescription() {
 
  142     boolean getFileSetIgnoresKnownFiles() {
 
  149     boolean getFileSetIgnoresUnallocatedSpace() {
 
  158     @SuppressWarnings(
"unchecked")
 
  170         org.openide.awt.Mnemonics.setLocalizedText(
nameLabel, 
org.openide.util.NbBundle.getMessage(
FilesSetPanel.class, 
"FilesSetPanel.interesting.nameLabel.text")); 
 
  172         descPanel.setBorder(javax.swing.BorderFactory.createTitledBorder(
org.openide.util.NbBundle.getMessage(
FilesSetPanel.class, 
"FilesSetPanel.descPanel.border.title"))); 
 
  180         javax.swing.GroupLayout descPanelLayout = 
new javax.swing.GroupLayout(
descPanel);
 
  182         descPanelLayout.setHorizontalGroup(
 
  183             descPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
 
  184             .addGroup(descPanelLayout.createSequentialGroup()
 
  189         descPanelLayout.setVerticalGroup(
 
  190             descPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
 
  191             .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, descPanelLayout.createSequentialGroup()
 
  192                 .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
 
  193                 .addComponent(
descScrollPanel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
 
  202         javax.swing.GroupLayout layout = 
new javax.swing.GroupLayout(
this);
 
  203         this.setLayout(layout);
 
  204         layout.setHorizontalGroup(
 
  205             layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
 
  206             .addGroup(layout.createSequentialGroup()
 
  208                 .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
 
  209                     .addComponent(
descPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
 
  210                     .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
 
  211                         .addGap(0, 0, Short.MAX_VALUE)
 
  212                         .addComponent(
nameLabel, javax.swing.GroupLayout.PREFERRED_SIZE, 71, javax.swing.GroupLayout.PREFERRED_SIZE)
 
  213                         .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
 
  214                         .addComponent(
nameTextField, javax.swing.GroupLayout.PREFERRED_SIZE, 299, javax.swing.GroupLayout.PREFERRED_SIZE))
 
  215                     .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
 
  216                         .addComponent(
ignoreKnownFilesCheckbox, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
 
  217                         .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
 
  218                         .addComponent(
ignoreUnallocCheckbox, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)))
 
  221         layout.setVerticalGroup(
 
  222             layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
 
  223             .addGroup(layout.createSequentialGroup()
 
  225                 .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
 
  227                     .addComponent(
nameTextField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
 
  228                 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
 
  229                 .addComponent(
descPanel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
 
  230                 .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
 
  231                 .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
 
  233                     .addComponent(
ignoreUnallocCheckbox, javax.swing.GroupLayout.PREFERRED_SIZE, 23, javax.swing.GroupLayout.PREFERRED_SIZE))
 
final String mustBeNamedErrorText
javax.swing.JPanel descPanel
javax.swing.JLabel nameLabel
javax.swing.JTextArea descTextArea
javax.swing.JCheckBox ignoreUnallocCheckbox
javax.swing.JTextField nameTextField
static final String CREATE_NEW_FILE_INGEST_FILTER
javax.swing.JCheckBox ignoreKnownFilesCheckbox
javax.swing.JScrollPane descScrollPanel
static String getCreateNewFileIngestFilterString()