Interface IPartialFileSerializer
Bcm file serialization interface that allows for not holding the full file in memory
Assembly: Sdl.Core.Bcm.BcmModel.dll
Syntax
public interface IPartialFileSerializer
Methods
AddParagraphUnit(ParagraphUnit)
Adds a paragraph unit at the end of the paragraph units list in the file
Declaration
void AddParagraphUnit(ParagraphUnit paragraphUnit)
Parameters
GetAllParagraphUnits()
Returns a sequence of paragraph units from this file, deserialized one by one
Declaration
IEnumerable<ParagraphUnit> GetAllParagraphUnits()
Returns
Type |
Description |
System.Collections.Generic.IEnumerable<ParagraphUnit> |
|
GetFileWithoutParagraphUnits()
Gets file attributes and skeleton without any paragraph units in it.
Declaration
File GetFileWithoutParagraphUnits()
Returns
GetParagraphUnitCount()
Returns the number of paragraph units in this file
Declaration
int GetParagraphUnitCount()
Returns
Type |
Description |
System.Int32 |
|
GetParagraphUnitIds()
Returns the paragraph unit ids from this file
Declaration
IReadOnlyList<string> GetParagraphUnitIds()
Returns
Type |
Description |
System.Collections.Generic.IReadOnlyList<System.String> |
|
GetSpecificParagraphUnit(Int32)
Deserializes the paragraph unit with specific index in file
Declaration
ParagraphUnit GetSpecificParagraphUnit(int index)
Parameters
Type |
Name |
Description |
System.Int32 |
index |
|
Returns
GetSpecificParagraphUnit(String)
Deserializes the paragraph unit with specific id in file
Declaration
ParagraphUnit GetSpecificParagraphUnit(string id)
Parameters
Type |
Name |
Description |
System.String |
id |
|
Returns
InsertParagraphUnit(Int32, ParagraphUnit)
Inserts paragraph unit at specific index in file
Declaration
void InsertParagraphUnit(int index, ParagraphUnit paragraphUnit)
Parameters
Type |
Name |
Description |
System.Int32 |
index |
|
ParagraphUnit |
paragraphUnit |
|
RemoveParagraphUnit(Int32)
Removes paragraph unit with specific index from file
Declaration
void RemoveParagraphUnit(int index)
Parameters
Type |
Name |
Description |
System.Int32 |
index |
|
RemoveParagraphUnit(String)
Removes paragraph unit from file
Declaration
void RemoveParagraphUnit(string id)
Parameters
Type |
Name |
Description |
System.String |
id |
|
RemoveParagraphUnitRange(Int32, Int32)
Removes multiple paragraph units based on index
Declaration
void RemoveParagraphUnitRange(int startIndex, int count)
Parameters
Type |
Name |
Description |
System.Int32 |
startIndex |
|
System.Int32 |
count |
|
UpdateFileDataWithoutParagraphUnits(File)
Updates file attributes and skeleton. Array of paragraph units must be empty.
Declaration
void UpdateFileDataWithoutParagraphUnits(File file)
Parameters
Type |
Name |
Description |
File |
file |
|
UpdateParagraphUnit(ParagraphUnit)
Updates paragraph unit in file
Declaration
void UpdateParagraphUnit(ParagraphUnit paragraphUnit)
Parameters