Play-/Source/ISO9660/PathTableRecord.cpp

43 lines
731 B
C++
Raw Permalink Normal View History

#include <stdlib.h>
#include "PathTableRecord.h"
using namespace ISO9660;
CPathTableRecord::CPathTableRecord(Framework::CStream& stream)
{
m_nameLength = stream.Read8();
m_exLength = stream.Read8();
m_location = stream.Read32();
m_parentDir = stream.Read16();
m_directory = stream.ReadString(m_nameLength);
2014-07-12 21:59:58 -04:00
if(m_nameLength & 1)
{
stream.Seek(1, Framework::STREAM_SEEK_CUR);
}
}
CPathTableRecord::~CPathTableRecord()
{
}
uint8 CPathTableRecord::GetNameLength() const
{
2014-07-12 21:59:58 -04:00
return m_nameLength;
}
uint32 CPathTableRecord::GetAddress() const
{
2014-07-12 21:59:58 -04:00
return m_location;
}
uint32 CPathTableRecord::GetParentRecord() const
{
2014-07-12 21:59:58 -04:00
return m_parentDir;
}
const char* CPathTableRecord::GetName() const
{
2014-07-12 21:59:58 -04:00
return m_directory.c_str();
}