Examples of TagsManager


Examples of org.sleuthkit.autopsy.casemodule.services.TagsManager

        return nonCatTagNames;
    }

    synchronized static public TagName getTagName(String displayName) throws TskCoreException {
        try {
            final TagsManager tagsManager = Case.getCurrentCase().getServices().getTagsManager();

            for (TagName tn : tagsManager.getAllTagNames()) {
                if (displayName.equals(tn.getDisplayName())) {
                    return tn;
                }
            }
            try {
                return tagsManager.addTagName(displayName);
            } catch (TagsManager.TagNameAlreadyExistsException ex) {
                throw new TskCoreException("tagame exists but wasn't found", ex);
            }
        } catch (IllegalStateException ex) {
            Logger.getLogger(TagUtils.class.getName()).log(Level.SEVERE, "Case was closed out from underneath", ex);
View Full Code Here

Examples of org.sleuthkit.autopsy.casemodule.services.TagsManager

        TagMenu() {
            super(getActionDisplayName());

            // Get the current set of tag names.
            TagsManager tagsManager = Case.getCurrentCase().getServices().getTagsManager();
            List<TagName> tagNames = null;
            try {
                tagNames = tagsManager.getAllTagNames();
            } catch (TskCoreException ex) {
                Logger.getLogger(TagsManager.class.getName()).log(Level.SEVERE, "Failed to get tag names", ex);
            }

            // Create a "Quick Tag" sub-menu.
View Full Code Here

Examples of org.sleuthkit.autopsy.casemodule.services.TagsManager

        }

        private void updateDisplayName() {
            long tagsCount = 0;
            try {
                TagsManager tm = Case.getCurrentCase().getServices().getTagsManager();
                tagsCount = tm.getContentTagsCountByTagName(tagName);
                tagsCount += tm.getBlackboardArtifactTagsCountByTagName(tagName);
            } catch (TskCoreException ex) {
                Logger.getLogger(TagNameNode.class.getName()).log(Level.SEVERE, "Failed to get tags count for " + tagName.getDisplayName() + " tag name", ex); //NON-NLS
            }
            setDisplayName(tagName.getDisplayName() + " (" + tagsCount + ")");
        }
View Full Code Here

Examples of org.sleuthkit.autopsy.casemodule.services.TagsManager

            }
        });
                               
        // Get the current set of tag names and hash them for a speedy lookup in
        // case the user chooses an existing tag name from the tag names table.
        TagsManager tagsManager = Case.getCurrentCase().getServices().getTagsManager();
        List<TagName> currentTagNames = null;
        try {
            currentTagNames = tagsManager.getAllTagNames();       
        }
        catch (TskCoreException ex) {
            Logger.getLogger(GetTagNameDialog.class.getName()).log(Level.SEVERE, "Failed to get tag names", ex); //NON-NLS
        }        
        if (null != currentTagNames) {
View Full Code Here

Examples of org.sleuthkit.autopsy.casemodule.services.TagsManager

            linkToThumbnail.append("<img src=\"").append(thumbnailPath).append("\" title=\"").append(nameInImage).append("\"/>"); //NON-NLS
            linkToThumbnail.append("</a><br>"); //NON-NLS
            linkToThumbnail.append(file.getName()).append("<br>"); //NON-NLS
           
            Services services = currentCase.getServices();
            TagsManager tagsManager = services.getTagsManager();
            try {
                List<ContentTag> tags = tagsManager.getContentTagsByContent(content);
                if (tags.size() > 0) {
                    linkToThumbnail.append(NbBundle.getMessage(this.getClass(), "ReportHTML.thumbLink.tags") );
                }
                for (int i = 0; i < tags.size(); i++) {
                    ContentTag tag = tags.get(i);
View Full Code Here

Examples of org.sleuthkit.autopsy.casemodule.services.TagsManager

    private class TagMenu extends JMenu {
        TagMenu() {
            super(getActionDisplayName());

            // Get the current set of tag names.
            TagsManager tagsManager = Case.getCurrentCase().getServices().getTagsManager();
            List<TagName> tagNames = null;
            try {
                tagNames = tagsManager.getAllTagNames();
            }
            catch (TskCoreException ex) {
                Logger.getLogger(TagsManager.class.getName()).log(Level.SEVERE, "Failed to get tag names", ex); //NON-NLS
            }
                       
View Full Code Here

Examples of org.sleuthkit.autopsy.casemodule.services.TagsManager

            }
        });
                       
        // Populate the combo box with the available tag names and save the
        // tag name DTOs to be enable to return the one the user selects.
        TagsManager tagsManager = Case.getCurrentCase().getServices().getTagsManager();
        List<TagName> currentTagNames = null;
        try {
            currentTagNames = tagsManager.getAllTagNames();       
        }
        catch (TskCoreException ex) {
            Logger.getLogger(GetTagNameAndCommentDialog.class.getName()).log(Level.SEVERE, "Failed to get tag names", ex); //NON-NLS
        }       
        if (null != currentTagNames && currentTagNames.isEmpty()) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.