1 /*
2 * SleuthKit Java Bindings
3 *
4 * Copyright 2011-2022 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
33
88 long objId,
89 long dataSourceObjectId,
90 long fsObjId,
92 String name,
97 long ctime, long crtime, long atime, long mtime,
101 String extension,
102 String ownerUid,
103 Long osAccountObjId,
105 List<Attribute> fileAttributes) {
107 metaAddr, metaSeq, dirType, metaType, dirFlag, metaFlags, size, ctime, crtime, atime, mtime,
108 modes, uid, gid, md5Hash, sha256Hash, sha1Hash, knownState, parentPath, mimeType, extension,
109 ownerUid, osAccountObjId, collected, fileAttributes);
110 }
111
120 @Override
122 return visitor.
visit(
this);
123 }
124
133 @Override
135 return v.
visit(
this);
136 }
137
147 @Override
149 return super.toString(preserveState) + "File [\t" + "]\t"; //NON-NLS
150 }
151
191 @Deprecated
192 @SuppressWarnings("deprecation")
194 long objId,
195 long fsObjId,
197 String name,
198 long metaAddr, int metaSeq,
201 long size,
202 long ctime, long crtime, long atime, long mtime,
203 short modes, int uid, int gid,
204 String md5Hash,
FileKnown knownState, String parentPath) {
205 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);
206 }
207
257 @Deprecated
258 @SuppressWarnings("deprecation")
261 TSK_FS_NAME_FLAG_ENUM dirFlag,
short metaFlags,
long size,
long ctime,
long crtime,
long atime,
long mtime,
262 short modes,
int uid,
int gid, String md5Hash,
FileKnown knownState, String parentPath, String mimeType) {
263 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, null, knownState, parentPath, mimeType, null,
OsAccount.NO_OWNER_ID,
OsAccount.NO_ACCOUNT, Collections.emptyList());
264 }
265
320 @Deprecated
321 @SuppressWarnings("deprecation")
322 File(SleuthkitCase db,
323 long objId,
324 long dataSourceObjectId,
325 long fsObjId,
326 TSK_FS_ATTR_TYPE_ENUM attrType, int attrId,
327 String name,
328 long metaAddr, int metaSeq,
329 TSK_FS_NAME_TYPE_ENUM dirType, TSK_FS_META_TYPE_ENUM metaType,
330 TSK_FS_NAME_FLAG_ENUM dirFlag, short metaFlags,
331 long size,
332 long ctime, long crtime, long atime, long mtime,
333 short modes, int uid, int gid,
334 String md5Hash, String sha256Hash, String sha1Hash,
335 FileKnown knownState, String parentPath, String mimeType,
336 String extension,
337 String ownerUid,
338 Long osAccountObjId,
339 List<Attribute> fileAttributes) {
340 this(db, objId, dataSourceObjectId, fsObjId,
attrType,
attrId, name,
341 metaAddr,
metaSeq,
dirType,
metaType,
dirFlag,
metaFlags,
size, ctime, crtime, atime, mtime,
342 modes,
uid, gid,
md5Hash,
sha256Hash,
sha1Hash,
knownState,
parentPath, mimeType, extension,
343 ownerUid, osAccountObjId, null, fileAttributes);
344 }
345 }
FS
File that can be found in file system tree.
final TSK_FS_NAME_TYPE_ENUM dirType
final TskData.TSK_FS_ATTR_TYPE_ENUM attrType
TSK_FS_NAME_FLAG_ENUM dirFlag
Set< TSK_FS_META_FLAG_ENUM > metaFlags
final Set< TskData.TSK_FS_META_MODE_ENUM > modes
TskData.FileKnown knownState
final TSK_FS_META_TYPE_ENUM metaType
String toString(boolean preserveState)