Go to the documentation of this file.
19package org.sleuthkit.autopsy.datamodel.hosts;
21import java.awt.event.ActionEvent;
22import java.util.Collections;
24import java.util.logging.Level;
25import javax.swing.AbstractAction;
26import javax.swing.JMenu;
27import javax.swing.JMenuItem;
28import javax.swing.JSeparator;
29import org.openide.util.NbBundle.Messages;
30import org.openide.util.actions.Presenter;
31import org.sleuthkit.autopsy.casemodule.Case;
32import org.sleuthkit.autopsy.casemodule.NoCurrentCaseException;
33import org.sleuthkit.autopsy.coreutils.Logger;
34import org.sleuthkit.datamodel.Host;
35import org.sleuthkit.datamodel.Person;
36import org.sleuthkit.datamodel.TskCoreException;
44 "AssociatePersonsMenuAction_menuTitle=Associate with Person",})
62 @SuppressWarnings(
"NoopMethodInAbstractClass")
68 JMenu menu =
new JMenu(Bundle.AssociatePersonsMenuAction_menuTitle());
70 List<Person> existingPersons = Collections.emptyList();
74 logger.log(Level.WARNING,
"Error getting persons for case.", ex);
77 existingPersons.stream()
78 .filter(p -> p !=
null && p.getName() !=
null)
79 .sorted((a, b) -> a.getName().compareToIgnoreCase(b.getName()))
83 if (menu.getItemCount() > 0) {
84 menu.add(
new JSeparator());
SleuthkitCase getSleuthkitCase()
static Case getCurrentCaseThrows()
synchronized static Logger getLogger(String name)
Copyright © 2012-2024 Sleuth Kit Labs. Generated on:
This work is licensed under a
Creative Commons Attribution-Share Alike 3.0 United States License.