Class MappedCrossOriginConfig

    • Method Detail

      • builder

        public static MappedCrossOriginConfig.Builder builder()
        Returns a new builder for creating a CrossOriginConfig.Mapped instance.
        Returns:
        the new builder
      • builder

        public static MappedCrossOriginConfig.Builder builder​(Config config)
        Creates a new Mapped.Builder instance using the provided configuration.

        Although this method is equivalent to builder().config(config) it conveniently combines those two steps for use as a method reference.

        Parameters:
        config - node containing Mapped cross-origin information
        Returns:
        new Mapped.Builder based on the config
      • create

        public static MappedCrossOriginConfig create​(Config config)
        Creates a new Mapped instance using the provided configuration.
        Parameters:
        config - node containing Mapped cross-origin information
        Returns:
        new Mapped instance based on the config
      • forEach

        public void forEach​(BiConsumer<String,​CrossOriginConfig> consumer)
        Invokes the specified consumer for each entry in the mapped CORS config.
        Parameters:
        consumer - accepts the path and the CrossOriginConfig for processing
      • get

        public CrossOriginConfig get​(String pathPattern)
        Finds the CrossOriginConfig associated with the given path expression, if any.
        Parameters:
        pathPattern - path expression to match on
        Returns:
        Optional of the corresponding basic cross-origin information
      • name

        public String name()
        Returns:
        the name set up for this CORS-enabled component or app
      • isEnabled

        public boolean isEnabled()
        Reports whether this instance is enabled.
        Returns:
        current enabled state