Package com.dylibso.chicory.wasm.types
Class ElementSection
- java.lang.Object
-
- com.dylibso.chicory.wasm.types.Section
-
- com.dylibso.chicory.wasm.types.ElementSection
-
public class ElementSection extends Section
-
-
Constructor Summary
Constructors Constructor Description ElementSection()Construct a new, empty section instance.ElementSection(int estimatedSize)Construct a new, empty section instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intaddElement(Element element)Add an element definition to this section.intelementCount()Element[]elements()ElementgetElement(int idx)
-
-
-
Method Detail
-
elements
public Element[] elements()
-
elementCount
public int elementCount()
-
getElement
public Element getElement(int idx)
-
addElement
public int addElement(Element element)
Add an element definition to this section.- Parameters:
element- the element to add to this section (must not benull)- Returns:
- the index of the newly-added element
-
-