Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
Sleuthkit
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
IRT
Sleuthkit
Commits
2127f6f7
Commit
2127f6f7
authored
5 years ago
by
Raman Arora
Browse files
Options
Downloads
Patches
Plain Diff
6128: Type match exception for TSK_COUNT attribute.
parent
095e0dfd
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
bindings/java/src/org/sleuthkit/datamodel/blackboardutils/ArtifactHelperBase.java
+19
-5
19 additions, 5 deletions
...euthkit/datamodel/blackboardutils/ArtifactHelperBase.java
with
19 additions
and
5 deletions
bindings/java/src/org/sleuthkit/datamodel/blackboardutils/ArtifactHelperBase.java
+
19
−
5
View file @
2127f6f7
/*
/*
* Sleuth Kit Data Model
* Sleuth Kit Data Model
*
*
* Copyright 2019 Basis Technology Corp.
* Copyright 2019
-2020
Basis Technology Corp.
* Contact: carrier <at> sleuthkit <dot> org
* Contact: carrier <at> sleuthkit <dot> org
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
...
@@ -75,11 +75,11 @@ String getModuleName() {
...
@@ -75,11 +75,11 @@ String getModuleName() {
}
}
/**
/**
* Creates and adds a
n
attribute of specified type to the given list, if the
* Creates and adds a
string
attribute of specified type to the given list, if the
* attribute value is not empty or null.
* attribute value is not empty or null.
*
*
* @param attributeType Attribute type.
* @param attributeType Attribute type.
* @param attrValue
A
ttribute value.
* @param attrValue
String a
ttribute value.
* @param attributes List of attributes to add to.
* @param attributes List of attributes to add to.
*
*
*/
*/
...
@@ -90,11 +90,11 @@ void addAttributeIfNotNull(BlackboardAttribute.ATTRIBUTE_TYPE attributeType, Str
...
@@ -90,11 +90,11 @@ void addAttributeIfNotNull(BlackboardAttribute.ATTRIBUTE_TYPE attributeType, Str
}
}
/**
/**
* Creates and adds a
n
attribute of specified type to the given list, if the
* Creates and adds a
long
attribute of specified type to the given list, if the
* attribute value is not 0.
* attribute value is not 0.
*
*
* @param attributeType Attribute type.
* @param attributeType Attribute type.
* @param attrValue
A
ttribute value.
* @param attrValue
Long a
ttribute value.
* @param attributes List of attributes to add to.
* @param attributes List of attributes to add to.
*/
*/
void
addAttributeIfNotZero
(
BlackboardAttribute
.
ATTRIBUTE_TYPE
attributeType
,
long
attrValue
,
Collection
<
BlackboardAttribute
>
attributes
)
{
void
addAttributeIfNotZero
(
BlackboardAttribute
.
ATTRIBUTE_TYPE
attributeType
,
long
attrValue
,
Collection
<
BlackboardAttribute
>
attributes
)
{
...
@@ -102,4 +102,18 @@ void addAttributeIfNotZero(BlackboardAttribute.ATTRIBUTE_TYPE attributeType, lon
...
@@ -102,4 +102,18 @@ void addAttributeIfNotZero(BlackboardAttribute.ATTRIBUTE_TYPE attributeType, lon
attributes
.
add
(
new
BlackboardAttribute
(
attributeType
,
getModuleName
(),
attrValue
));
attributes
.
add
(
new
BlackboardAttribute
(
attributeType
,
getModuleName
(),
attrValue
));
}
}
}
}
/**
* Creates and adds an integer attribute of specified type to the given list, if the
* attribute value is not 0.
*
* @param attributeType Attribute type.
* @param attrValue Integer attribute value.
* @param attributes List of attributes to add to.
*/
void
addAttributeIfNotZero
(
BlackboardAttribute
.
ATTRIBUTE_TYPE
attributeType
,
int
attrValue
,
Collection
<
BlackboardAttribute
>
attributes
)
{
if
(
attrValue
>
0
)
{
attributes
.
add
(
new
BlackboardAttribute
(
attributeType
,
getModuleName
(),
attrValue
));
}
}
}
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment