The Sleuth Kit 4.15.0-develop
TskVsPartInfo Class Reference

Stores information about a volume / partition inside of an open volume system. More...

#include <tsk_vs.h>

Public Member Functions

TSK_PNUM_T getAddr () const
 Return address of this partition.
const char * getDesc () const
 Return UTF-8 description of partition (volume system type-specific).
TSK_VS_PART_FLAG_ENUM getFlags () const
 Return flags for partition.
TSK_DADDR_T getLen () const
 Return number of sectors in partition.
int16_t getSlotNum () const
 Return entry in the table that describes this partition.
TSK_DADDR_T getStart () const
 Return sector offset of start of partition.
int8_t getTableNum () const
 Return table address that describes this partition.
ssize_t read (TSK_OFF_T a_off, char *a_buf, size_t a_len)
 Reads data starting at a byte address relative to the start of a VOLUME in a volume system.
ssize_t readBlock (TSK_DADDR_T a_addr, char *a_buf, size_t a_len)
 Reads one or more blocks of data with an address relative to the start of a VOLUME in a volume system.
 TskVsPartInfo (TSK_VS_PART_INFO *a_vsPartInfo)
 Create an object from its C struct.

Friends

class TskFsInfo

Detailed Description

Stores information about a volume / partition inside of an open volume system.

Constructor & Destructor Documentation

◆ TskVsPartInfo()

TskVsPartInfo::TskVsPartInfo ( TSK_VS_PART_INFO * a_vsPartInfo)
inline

Create an object from its C struct.

Parameters
a_vsPartInfoPointer to C struct for partition. If NULL, the remaining getX() methods will be undefined.

Member Function Documentation

◆ getAddr()

TSK_PNUM_T TskVsPartInfo::getAddr ( ) const
inline

Return address of this partition.

Returns
address of this partition

◆ getDesc()

const char * TskVsPartInfo::getDesc ( ) const
inline

Return UTF-8 description of partition (volume system type-specific).

Returns
description of partition

◆ getFlags()

TSK_VS_PART_FLAG_ENUM TskVsPartInfo::getFlags ( ) const
inline

Return flags for partition.

Returns
flags for partition

◆ getLen()

TSK_DADDR_T TskVsPartInfo::getLen ( ) const
inline

Return number of sectors in partition.

Returns
number of sectors in partition

◆ getSlotNum()

int16_t TskVsPartInfo::getSlotNum ( ) const
inline

Return entry in the table that describes this partition.

Returns
entry in the table that describes this partition

◆ getStart()

TSK_DADDR_T TskVsPartInfo::getStart ( ) const
inline

Return sector offset of start of partition.

Returns
sector offset of start of partition

◆ getTableNum()

int8_t TskVsPartInfo::getTableNum ( ) const
inline

Return table address that describes this partition.

Returns
table address that describes this partition

◆ read()

ssize_t TskVsPartInfo::read ( TSK_OFF_T a_off,
char * a_buf,
size_t a_len )
inline

Reads data starting at a byte address relative to the start of a VOLUME in a volume system.

See tsk_vs_part_read() for details.

Parameters
a_offByte offset to read from, relative to start of VOLUME in volume system.
a_bufBuffer to store data in
a_lenAmount of data to read (in bytes)
Returns
Number of bytes read or -1 on error

References tsk_vs_part_read().

◆ readBlock()

ssize_t TskVsPartInfo::readBlock ( TSK_DADDR_T a_addr,
char * a_buf,
size_t a_len )
inline

Reads one or more blocks of data with an address relative to the start of a VOLUME in a volume system.

See tsk_vs_part_read_block() for details.

Parameters
a_addrBlock address to start reading from, relative to start of VOLUME in volume system.
a_bufBuffer to store data in
a_lenAmount of data to read (in bytes - must be a multiple of block_size)
Returns
Number of bytes read or -1 on error

References tsk_vs_part_read_block().


The documentation for this class was generated from the following file:

Copyright © 2007-2020 Brian Carrier. (carrier -at- sleuthkit -dot- org)
This work is licensed under a Creative Commons Attribution-Share Alike 3.0 United States License.