Package com.dylibso.chicory.wasm.types
Class DataSection
- java.lang.Object
-
- com.dylibso.chicory.wasm.types.Section
-
- com.dylibso.chicory.wasm.types.DataSection
-
public class DataSection extends Section
-
-
Constructor Summary
Constructors Constructor Description DataSection()Construct a new, empty section instance.DataSection(int estimatedSize)Construct a new, empty section instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intaddDataSegment(DataSegment dataSegment)Add a data segment definition to this section.intdataSegmentCount()DataSegment[]dataSegments()DataSegmentgetDataSegment(int idx)
-
-
-
Method Detail
-
dataSegments
public DataSegment[] dataSegments()
-
dataSegmentCount
public int dataSegmentCount()
-
getDataSegment
public DataSegment getDataSegment(int idx)
-
addDataSegment
public int addDataSegment(DataSegment dataSegment)
Add a data segment definition to this section.- Parameters:
dataSegment- the data segment to add to this section (must not benull)- Returns:
- the index of the newly-added data segment
-
-