19 package org.sleuthkit.datamodel;
21 import java.util.ArrayList;
22 import java.util.Collections;
23 import java.util.HashSet;
25 import java.util.logging.Level;
26 import java.util.logging.Logger;
55 checkedHasChildren =
false;
72 if (uniquePath == null) {
74 if (!name.isEmpty()) {
79 if (myParent != null) {
88 if (checkedHasChildren ==
true) {
93 checkedHasChildren =
true;
104 if (childrenCount != -1) {
110 hasChildren = childrenCount > 0;
111 checkedHasChildren =
true;
118 if (parent == null) {
119 ObjectInfo parentInfo;
121 parentInfo = db.getParentInfo(
this);
122 }
catch (TskCoreException ex) {
131 void setParent(
Content parent) {
142 void setParentId(
long parentId) {
155 if (myParent == null) {
176 if (getClass() != obj.getClass()) {
180 if (this.objId != other.
objId) {
199 int hash = 7 + (int) (this.objId ^ (this.objId >>> 32));
230 if (genInfoArtifact == null)
235 ArrayList<BlackboardArtifact> list =
new ArrayList<BlackboardArtifact>();
237 if (genInfoArtifact != null) {
238 list.add(genInfoArtifact);
257 if (genInfoArtifact != null) {
264 if (arts.isEmpty()) {
271 retArt = arts.get(0);
273 genInfoArtifact = retArt;
279 ArrayList<BlackboardAttribute> returnList =
new ArrayList<BlackboardAttribute>();
281 if (genInfoArtifact == null) {
283 if (genInfoArtifact == null) {
289 if (attribute.getAttributeType().getTypeID() == attr_type.getTypeID()) {
290 returnList.add(attribute);
324 Set<String> hashNames =
new HashSet<String>();
329 if (attribute != null) {
333 return Collections.unmodifiableSet(hashNames);
343 return "AbstractContent [\t" +
"objId " + String.format(
"%010d", objId) +
"\t"
344 +
"name " + name +
"\t" +
"parentId " + parentId +
"\t"
345 +
"\t" +
"checkedHasChildren " + checkedHasChildren
346 +
"\t" +
"hasChildren " + hasChildren
347 +
"\t" +
"childrenCount " + childrenCount
348 +
"uniquePath " + uniquePath +
"]\t";
352 return "AbstractContent [\t" +
"objId " + String.format(
"%010d", objId)
353 +
"\t" +
"name " + name
354 +
"\t" +
"checkedHasChildren " + checkedHasChildren
355 +
"\t" +
"hasChildren " + hasChildren
356 +
"\t" +
"childrenCount " + childrenCount
360 return "AbstractContent [\t" +
"objId "
361 + String.format(
"%010d", objId) +
"\t" +
"name " + name
362 +
"\t" +
"checkedHasChildren " + checkedHasChildren
363 +
"\t" +
"hasChildren " + hasChildren
364 +
"\t" +
"childrenCount " + childrenCount
366 +
"\t" +
"parentId " + parentId +
"]\t";
370 return "AbstractContent [\t" +
"objId " + String.format(
"%010d", objId) +
"\t"
371 +
"name " + name +
"\t" +
"parentId " + parentId +
"\t"
372 +
"\t" +
"checkedHasChildren " + checkedHasChildren
373 +
"\t" +
"hasChildren " + hasChildren
374 +
"\t" +
"childrenCount " + childrenCount
375 +
"uniquePath " + uniquePath +
"]\t";
volatile boolean hasChildren
long getBlackboardArtifactsCount(long objId)
synchronized Content getParent()
ArrayList< BlackboardArtifact > getBlackboardArtifacts(int artifactTypeID)
ArrayList< BlackboardArtifact > getArtifacts(int artifactTypeID)
TSK_HASHSET_HIT
hashset hits
Content getContentById(long id)
ArrayList< BlackboardArtifact > getAllArtifacts()
TSK_GEN_INFO
Default type.
synchronized String getUniquePath()
String toString(boolean preserveState)
ArrayList< BlackboardArtifact > getMatchingArtifacts(String whereClause)
volatile int childrenCount
BlackboardArtifact newArtifact(BlackboardArtifact.ARTIFACT_TYPE type)
ArrayList< BlackboardArtifact > getArtifacts(BlackboardArtifact.ARTIFACT_TYPE type)
BlackboardArtifact newBlackboardArtifact(int artifactTypeID, long obj_id)
BlackboardArtifact getGenInfoArtifact()
AbstractContent(SleuthkitCase db, long obj_id, String name)
SleuthkitCase getSleuthkitCase()
boolean equals(Object obj)
BlackboardArtifact.Type getArtifactType(String artTypeName)
BlackboardArtifact genInfoArtifact
long getArtifactsCount(ARTIFACT_TYPE type)
long getAllArtifactsCount()
List< BlackboardAttribute > getAttributes()
BlackboardArtifact newArtifact(int artifactTypeID)
Set< String > getHashSetNames()
long getArtifactsCount(int artifactTypeID)
ArrayList< BlackboardArtifact > getArtifacts(String artifactTypeName)
volatile boolean checkedHasChildren
static final long UNKNOWN_ID
BlackboardArtifact getGenInfoArtifact(boolean create)
ArrayList< BlackboardAttribute > getGenInfoAttributes(ATTRIBUTE_TYPE attr_type)
long getArtifactsCount(String artifactTypeName)