Go to the documentation of this file.
19package org.sleuthkit.autopsy.casemodule.events;
21import java.util.ArrayList;
22import java.util.Collections;
24import java.util.Optional;
25import org.sleuthkit.autopsy.casemodule.Case;
26import org.sleuthkit.datamodel.Host;
27import org.sleuthkit.datamodel.Person;
28import org.sleuthkit.datamodel.SleuthkitCase;
29import org.sleuthkit.datamodel.TskCoreException;
69 protected List<Person>
getOldValueObjects(SleuthkitCase caseDb, List<Long> ids)
throws TskCoreException {
70 List<Person> persons =
new ArrayList<>();
72 Optional<Person> person = caseDb.getPersonManager().getPerson(
id);
73 if (person.isPresent()) {
74 persons.add(person.get());
81 protected List<Host>
getNewValueObjects(SleuthkitCase caseDb, List<Long> ids)
throws TskCoreException {
82 List<Host> hosts =
new ArrayList<>();
84 Optional<Host> host = caseDb.getHostManager().getHostById(
id);
85 if (host.isPresent()) {
86 hosts.add(host.get());
List< Person > getOldValueObjects(SleuthkitCase caseDb, List< Long > ids)
static final long serialVersionUID
HostsAddedToPersonEvent(Person person, List< Host > hosts)
List< Host > getNewValueObjects(SleuthkitCase caseDb, List< Long > ids)
TskDataModelChangedEvent(String eventName, List< T > oldValueObjects, Function< T, Long > oldValueGetIdMethod, List< U > newValueObjects, Function< U, Long > newValueGetIdMethod)
Copyright © 2012-2024 Sleuth Kit Labs. Generated on:
This work is licensed under a
Creative Commons Attribution-Share Alike 3.0 United States License.