Class StringScriptResource

    • Constructor Detail

      • StringScriptResource

        public StringScriptResource​(@Nonnull
                                    String source,
                                    @Nonnull
                                    String name)
        Creates a simple script resource based on a string.
        Parameters:
        source - The source code
        name - the name of this source
    • Method Detail

      • getName

        public String getName()
        Gets the name (path) of the resource
        Specified by:
        getName in interface ScriptResource
        Returns:
        the name
      • getSize

        public long getSize()
        Returns the size of this resource
        Specified by:
        getSize in interface ScriptResource
        Returns:
        the size or -1 if not known