Autopsy  4.1
Graphical digital forensics platform for The Sleuth Kit and other tools.
TagDeletedEvent.java
Go to the documentation of this file.
1 /*
2  * Autopsy Forensic Browser
3  *
4  * Copyright 2015 Basis Technology Corp.
5  * Contact: carrier <at> sleuthkit <dot> org
6  *
7  * Licensed under the Apache License, Version 2.0 (the "License");
8  * you may not use this file except in compliance with the License.
9  * You may obtain a copy of the License at
10  *
11  * http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing, software
14  * distributed under the License is distributed on an "AS IS" BASIS,
15  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16  * See the License for the specific language governing permissions and
17  * limitations under the License.
18  */
19 package org.sleuthkit.autopsy.casemodule.events;
20 
21 import java.io.Serializable;
22 import javax.annotation.concurrent.Immutable;
24 import org.sleuthkit.datamodel.Tag;
25 import org.sleuthkit.datamodel.TagName;
26 
30 @Immutable
31 abstract class TagDeletedEvent<T extends Tag> extends AutopsyEvent implements Serializable {
32 
33  private static final long serialVersionUID = 1L;
34 
35  TagDeletedEvent(String propertyName, DeletedTagInfo<T> deletedTagInfo) {
36  super(propertyName, deletedTagInfo, null);
37  }
38 
47  @SuppressWarnings("unchecked")
48  abstract public DeletedTagInfo<T> getDeletedTagInfo();
49 
58  @Immutable
59  abstract static class DeletedTagInfo<T extends Tag> implements Serializable {
60 
61  private static final long serialVersionUID = 1L;
62 
63  private final String comment;
64  private final long tagID;
65  private final TagName name;
66 
67  DeletedTagInfo(T deletedTag) {
68  comment = deletedTag.getComment();
69  tagID = deletedTag.getId();
70  name = deletedTag.getName();
71  }
72 
73  abstract public long getContentID();
74 
75  public String getComment() {
76  return comment;
77  }
78 
79  public long getTagID() {
80  return tagID;
81  }
82 
83  public TagName getName() {
84  return name;
85  }
86  }
87 }

Copyright © 2012-2016 Basis Technology. Generated on: Mon Jan 2 2017
This work is licensed under a Creative Commons Attribution-Share Alike 3.0 United States License.