Class WatCodeSyntheticFunctionName

    • Field Detail

      • code

        private final java.lang.String code
    • Constructor Detail

      • WatCodeSyntheticFunctionName

        public WatCodeSyntheticFunctionName​(java.lang.String name,
                                            java.lang.String code,
                                            AnyType... signatureTypes)
        Create a new instance.
        Parameters:
        name - the function name
        code - the WAT code (WASM in text form)
        signatureTypes - the method signature, first the parameters, then null and the the return types
      • WatCodeSyntheticFunctionName

        public WatCodeSyntheticFunctionName​(java.lang.String className,
                                            java.lang.String name,
                                            java.lang.String signature,
                                            @Nonnull
                                            java.lang.String code,
                                            AnyType... signatureTypes)
        Create a new instance.
        Parameters:
        className - the Java class name
        name - the function name
        code - the WAT code (WASM in text form)
        signature - the string signature
        signatureTypes - the method signature, first the parameters, then null and the the return types
    • Method Detail

      • getCode

        @Nonnull
        protected java.lang.String getCode()
        Get Wat code, can be overridden.
        Returns:
        the code
      • hasWasmCode

        protected boolean hasWasmCode()
        If this function has WASM code or if this function is a import with JavaScript code.
        Specified by:
        hasWasmCode in class SyntheticFunctionName
        Returns:
        true, if WASM code