mirror of
https://github.com/billsonnn/nitro-renderer.git
synced 2024-11-22 23:50:52 +01:00
added some method to get data from legacy data type using offsets
This commit is contained in:
parent
81cfd5c56f
commit
52db7aa550
@ -14,7 +14,6 @@ export class LegacyDataType extends ObjectDataBase implements IObjectData
|
||||
constructor()
|
||||
{
|
||||
super();
|
||||
|
||||
this._data = '';
|
||||
}
|
||||
|
||||
@ -47,6 +46,11 @@ export class LegacyDataType extends ObjectDataBase implements IObjectData
|
||||
return this._data;
|
||||
}
|
||||
|
||||
public getLegacyStringWithOffset(offset: number)
|
||||
{
|
||||
return this._data.split('\n')[offset];
|
||||
}
|
||||
|
||||
public compare(data: IObjectData): boolean
|
||||
{
|
||||
return (this._data === data.getLegacyString());
|
||||
|
Loading…
Reference in New Issue
Block a user