mirror of
https://github.com/SubtitleEdit/subtitleedit.git
synced 2024-11-22 19:22:53 +01:00
54 lines
1.1 KiB
C#
54 lines
1.1 KiB
C#
namespace Nikse.SubtitleEdit.Core.ContainerFormats.Ebml
|
|
{
|
|
internal class Element
|
|
{
|
|
private readonly ElementId _id;
|
|
private readonly long _dataPosition;
|
|
private readonly long _dataSize;
|
|
|
|
public Element(ElementId id, long dataPosition, long dataSize)
|
|
{
|
|
_id = id;
|
|
_dataPosition = dataPosition;
|
|
_dataSize = dataSize;
|
|
}
|
|
|
|
public ElementId Id
|
|
{
|
|
get
|
|
{
|
|
return _id;
|
|
}
|
|
}
|
|
|
|
public long DataPosition
|
|
{
|
|
get
|
|
{
|
|
return _dataPosition;
|
|
}
|
|
}
|
|
|
|
public long DataSize
|
|
{
|
|
get
|
|
{
|
|
return _dataSize;
|
|
}
|
|
}
|
|
|
|
public long EndPosition
|
|
{
|
|
get
|
|
{
|
|
return _dataPosition + _dataSize;
|
|
}
|
|
}
|
|
|
|
public override string ToString()
|
|
{
|
|
return string.Format(@"{0} ({1})", _id, _dataSize);
|
|
}
|
|
}
|
|
}
|