Sleuth Kit Java Bindings (JNI)  4.11.1
Java bindings for using The Sleuth Kit
org.sleuthkit.datamodel.PersonManager Class Reference

Public Member Functions

void addHostsToPerson (Person person, List< Host > hosts) throws TskCoreException
 
void deletePerson (String name) throws TskCoreException
 
List< HostgetHostsForPerson (Person person) throws TskCoreException
 
List< HostgetHostsWithoutPersons () throws TskCoreException
 
Optional< PersongetPerson (String name) throws TskCoreException
 
Optional< PersongetPerson (long id) throws TskCoreException
 
Optional< PersongetPerson (Host host) throws TskCoreException
 
List< PersongetPersons () throws TskCoreException
 
Person newPerson (String name) throws TskCoreException
 
void removeHostsFromPerson (Person person, List< Host > hosts) throws TskCoreException
 
Person updatePerson (Person person) throws TskCoreException
 

Detailed Description

Responsible for creating/updating/retrieving Persons.

Definition at line 37 of file PersonManager.java.

Member Function Documentation

void org.sleuthkit.datamodel.PersonManager.addHostsToPerson ( Person  person,
List< Host hosts 
) throws TskCoreException

Adds one or more hosts to a person.

Parameters
personThe person.
hostsThe hosts.
Exceptions
TskCoreExceptionThrown if the operation cannot be completed.

Definition at line 389 of file PersonManager.java.

void org.sleuthkit.datamodel.PersonManager.deletePerson ( String  name) throws TskCoreException

Delete a person. Name comparison is case-insensitive.

Parameters
nameName of the person to delete
Exceptions
TskCoreException

Definition at line 120 of file PersonManager.java.

References org.sleuthkit.datamodel.SleuthkitCase.acquireSingleUserCaseWriteLock(), org.sleuthkit.datamodel.Person.getPersonId(), and org.sleuthkit.datamodel.SleuthkitCase.releaseSingleUserCaseWriteLock().

List<Host> org.sleuthkit.datamodel.PersonManager.getHostsForPerson ( Person  person) throws TskCoreException

Get all hosts associated with the given person.

Parameters
personThe person.
Returns
The list of hosts corresponding to the person.
Exceptions
TskCoreExceptionThrown if there is an issue querying the case database.

Definition at line 272 of file PersonManager.java.

List<Host> org.sleuthkit.datamodel.PersonManager.getHostsWithoutPersons ( ) throws TskCoreException

Gets all hosts not associated with any person.

Returns
The hosts.
Exceptions
TskCoreExceptionThrown if there is an issue querying the case database.

Definition at line 284 of file PersonManager.java.

Optional<Person> org.sleuthkit.datamodel.PersonManager.getPerson ( String  name) throws TskCoreException

Get person with given name. Name comparison is case-insensitive.

Parameters
namePerson name to look for.
Returns
Optional with person. Optional.empty if no matching person is found.
Exceptions
TskCoreException

Definition at line 158 of file PersonManager.java.

References org.sleuthkit.datamodel.SleuthkitCase.acquireSingleUserCaseReadLock(), and org.sleuthkit.datamodel.SleuthkitCase.releaseSingleUserCaseReadLock().

Referenced by org.sleuthkit.datamodel.PersonManager.newPerson().

Optional<Person> org.sleuthkit.datamodel.PersonManager.getPerson ( long  id) throws TskCoreException

Get person with given id.

Parameters
idId of the person to look for.
Returns
Optional with person. Optional.empty if no matching person is found.
Exceptions
TskCoreException

Definition at line 177 of file PersonManager.java.

References org.sleuthkit.datamodel.SleuthkitCase.acquireSingleUserCaseReadLock(), and org.sleuthkit.datamodel.SleuthkitCase.releaseSingleUserCaseReadLock().

Optional<Person> org.sleuthkit.datamodel.PersonManager.getPerson ( Host  host) throws TskCoreException

Get person for the given host or empty if no associated person.

Parameters
hostThe host.
Returns
The parent person or empty if no parent person.
Exceptions
TskCoreExceptionif error occurs.

Definition at line 357 of file PersonManager.java.

References org.sleuthkit.datamodel.SleuthkitCase.acquireSingleUserCaseReadLock(), and org.sleuthkit.datamodel.SleuthkitCase.releaseSingleUserCaseReadLock().

List<Person> org.sleuthkit.datamodel.PersonManager.getPersons ( ) throws TskCoreException

Get all persons in the database.

Returns
List of persons
Exceptions
TskCoreException

Definition at line 58 of file PersonManager.java.

References org.sleuthkit.datamodel.SleuthkitCase.acquireSingleUserCaseReadLock(), and org.sleuthkit.datamodel.SleuthkitCase.releaseSingleUserCaseReadLock().

Person org.sleuthkit.datamodel.PersonManager.newPerson ( String  name) throws TskCoreException

Create a person with specified name. If a person already exists with the given name, it returns the existing person. Name comparison is case-insensitive.

Parameters
namePerson name.
Returns
Person with the specified name.
Exceptions
TskCoreException

Definition at line 207 of file PersonManager.java.

References org.sleuthkit.datamodel.SleuthkitCase.acquireSingleUserCaseWriteLock(), org.sleuthkit.datamodel.PersonManager.getPerson(), and org.sleuthkit.datamodel.SleuthkitCase.releaseSingleUserCaseWriteLock().

void org.sleuthkit.datamodel.PersonManager.removeHostsFromPerson ( Person  person,
List< Host hosts 
) throws TskCoreException

Removes one or more hosts from a person.

Parameters
personThe person.
hostsThe hosts.
Exceptions
TskCoreExceptionThrown if the operation cannot be completed.

Definition at line 407 of file PersonManager.java.

Person org.sleuthkit.datamodel.PersonManager.updatePerson ( Person  person) throws TskCoreException

Update the database to match the given Person.

Parameters
personThe person to update.
Returns
person The person that was updated.
Exceptions
TskCoreException

Definition at line 88 of file PersonManager.java.

References org.sleuthkit.datamodel.SleuthkitCase.acquireSingleUserCaseWriteLock(), and org.sleuthkit.datamodel.SleuthkitCase.releaseSingleUserCaseWriteLock().


The documentation for this class was generated from the following file:

Copyright © 2011-2021 Brian Carrier. (carrier -at- sleuthkit -dot- org)
This work is licensed under a Creative Commons Attribution-Share Alike 3.0 United States License.