Class TypeManager.BlockType

  • All Implemented Interfaces:
    AnyType
    Enclosing class:
    TypeManager

    public static class TypeManager.BlockType
    extends java.lang.Object
    implements AnyType
    A type that can use for a block
    • Field Detail

      • params

        @Nonnull
        private final java.util.List<AnyType> params
      • results

        @Nonnull
        private final java.util.List<AnyType> results
      • code

        private int code
      • name

        private java.lang.String name
    • Constructor Detail

      • BlockType

        public BlockType​(java.util.List<AnyType> params,
                         java.util.List<AnyType> results)
    • Method Detail

      • getCode

        public int getCode()
        The type code(typeidx) in WebAssembly. Predefined types have an negative typeidx. Custom types have the positive index in the type section.
        Specified by:
        getCode in interface AnyType
        Returns:
        the code
      • isRefType

        public boolean isRefType()
        If the type is a reference type. A GC reference to the heap.
        Specified by:
        isRefType in interface AnyType
        Returns:
        true, is GC type
      • isSubTypeOf

        public boolean isSubTypeOf​(AnyType type)
        Check if this is a sub type of given type.
        Specified by:
        isSubTypeOf in interface AnyType
        Parameters:
        type - type to check
        Returns:
        true, if both are identical or this is a sub type of other. Or if other is a parent type of this.
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • getParams

        public java.util.List<AnyType> getParams()
      • getResults

        public java.util.List<AnyType> getResults()
      • setName

        public void setName​(java.lang.String name)