Sleuth Kit Java Bindings (JNI)  4.10.2
Java bindings for using The Sleuth Kit
File.java
Go to the documentation of this file.
1 /*
2  * SleuthKit Java Bindings
3  *
4  * Copyright 2011-2017 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.datamodel;
20 
21 import java.util.Collections;
22 import java.util.List;
28 
32 public class File extends FsContent {
33 
86  long objId,
87  long dataSourceObjectId,
88  long fsObjId,
90  String name,
91  long metaAddr, int metaSeq,
94  long size,
95  long ctime, long crtime, long atime, long mtime,
96  short modes, int uid, int gid,
97  String md5Hash, String sha256Hash, FileKnown knownState, String parentPath, String mimeType,
98  String extension,
99  String ownerUid,
100  Long osAccountObjId,
101  List<Attribute> fileAttributes) {
102  super(db, objId, dataSourceObjectId, fsObjId, attrType, attrId, name, TskData.TSK_DB_FILES_TYPE_ENUM.FS, metaAddr, metaSeq, dirType, metaType, dirFlag, metaFlags, size, ctime, crtime, atime, mtime, modes, uid, gid, md5Hash, sha256Hash, knownState, parentPath, mimeType, extension, ownerUid, osAccountObjId, fileAttributes);
103  }
104 
113  @Override
114  public <T> T accept(SleuthkitItemVisitor<T> visitor) {
115  return visitor.visit(this);
116  }
117 
126  @Override
127  public <T> T accept(ContentVisitor<T> v) {
128  return v.visit(this);
129  }
130 
140  @Override
141  public String toString(boolean preserveState) {
142  return super.toString(preserveState) + "File [\t" + "]\t"; //NON-NLS
143  }
144 
184  @Deprecated
185  @SuppressWarnings("deprecation")
186  protected File(SleuthkitCase db,
187  long objId,
188  long fsObjId,
189  TSK_FS_ATTR_TYPE_ENUM attrType, short attrId,
190  String name,
191  long metaAddr, int metaSeq,
193  TSK_FS_NAME_FLAG_ENUM dirFlag, short metaFlags,
194  long size,
195  long ctime, long crtime, long atime, long mtime,
196  short modes, int uid, int gid,
197  String md5Hash, FileKnown knownState, String parentPath) {
198  this(db, objId, db.getDataSourceObjectId(objId), fsObjId, attrType, attrId, name, metaAddr, metaSeq, dirType, metaType, dirFlag, metaFlags, size, ctime, crtime, atime, mtime, modes, uid, gid, md5Hash, knownState, parentPath, null);
199  }
200 
250  @Deprecated
251  @SuppressWarnings("deprecation")
252  File(SleuthkitCase db, long objId, long dataSourceObjectId, long fsObjId, TSK_FS_ATTR_TYPE_ENUM attrType, short attrId,
253  String name, long metaAddr, int metaSeq, TSK_FS_NAME_TYPE_ENUM dirType, TSK_FS_META_TYPE_ENUM metaType,
254  TSK_FS_NAME_FLAG_ENUM dirFlag, short metaFlags, long size, long ctime, long crtime, long atime, long mtime,
255  short modes, int uid, int gid, String md5Hash, FileKnown knownState, String parentPath, String mimeType) {
256  this(db, objId, dataSourceObjectId, fsObjId, attrType, (int) attrId, name, metaAddr, metaSeq, dirType, metaType, dirFlag, metaFlags, size, ctime, crtime, atime, mtime, modes, uid, gid, md5Hash, null, knownState, parentPath, mimeType, null, OsAccount.NO_OWNER_ID, OsAccount.NO_ACCOUNT, Collections.emptyList());
257  }
258 }
FS
File that can be found in file system tree.
Definition: TskData.java:678
final TSK_FS_NAME_TYPE_ENUM dirType
final TskData.TSK_FS_ATTR_TYPE_ENUM attrType
Set< TSK_FS_META_FLAG_ENUM > metaFlags
final Set< TskData.TSK_FS_META_MODE_ENUM > modes
final TSK_FS_META_TYPE_ENUM metaType
String toString(boolean preserveState)
Definition: File.java:141

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.