Class EmulatorBuilder


  • public class EmulatorBuilder
    extends Object
    The builder for creating new emulator.
    Author:
    pao
    • Constructor Detail

      • EmulatorBuilder

        public EmulatorBuilder()
    • Method Detail

      • addContentRoot

        public EmulatorBuilder addContentRoot​(String contentRootPathOrUrl)
        add additional resource root directory.
        Parameters:
        contentRootPathOrUrl - directory path.
        Returns:
        self reference.
      • addContentRoot

        public EmulatorBuilder addContentRoot​(URL contentRoot)
        add additional resource root directory.
        Parameters:
        contentRoot - directory url.
        Returns:
        self reference.
      • setDescriptor

        public EmulatorBuilder setDescriptor​(String descriptor)
        specify the path of web.xml. default value is "./WEB-INF/web.xml".
        Parameters:
        descriptor - path of web.xml
        Returns:
        self reference.
      • create

        public Emulator create()
        create new emulator using current configuration.
        Returns:
        a new emulator