Packages

abstract class CorsSettings extends javadsl.settings.CorsSettings

Settings used by the CORS directives.

Public API but not intended for subclassing.

Linear Supertypes
Known Subclasses
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. CorsSettings
  2. CorsSettings
  3. AnyRef
  4. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new CorsSettings()

Abstract Value Members

  1. abstract def allowCredentials: Boolean

    Indicates whether the resource supports user credentials.

    Indicates whether the resource supports user credentials. If true, the header Access-Control-Allow-Credentials is set in the response, indicating that the actual request can include user credentials. Examples of user credentials are: cookies, HTTP authentication or client-side certificates.

    Default: true

    See also

    Access-Control-Allow-Credentials

  2. abstract def allowGenericHttpRequests: Boolean

    If true, allow generic requests (that are outside the scope of the specification) to pass through the directive.

    If true, allow generic requests (that are outside the scope of the specification) to pass through the directive. Else, strict CORS filtering is applied and any invalid request will be rejected.

    Default: true

  3. abstract def allowedHeaders: HttpHeaderRange

    List of request headers that can be used when making an actual request.

    List of request headers that can be used when making an actual request. Controls the content of the Access-Control-Allow-Headers header in a preflight response: if parameter is *, the headers from Access-Control-Request-Headers are echoed. Otherwise the parameter list is returned as part of the header.

    Default: HttpHeaderRange.*

    See also

    Access-Control-Allow-Headers

  4. abstract def allowedMethods: Seq[HttpMethod]

    List of methods that can be used when making an actual request.

    List of methods that can be used when making an actual request. The list is returned as part of the Access-Control-Allow-Methods preflight response header.

    The preflight request will be rejected if the Access-Control-Request-Method header's method is not part of the list.

    Default: Seq(GET, POST, HEAD, OPTIONS)

    See also

    Access-Control-Allow-Methods

  5. abstract def allowedOrigins: HttpOriginRange

    List of origins that the CORS filter must allow.

    List of origins that the CORS filter must allow. Can also be set to * to allow access to the resource from any origin. Controls the content of the Access-Control-Allow-Origin response header: if parameter is * and credentials are not allowed, a * is set in Access-Control-Allow-Origin. Otherwise, the origins given in the Origin request header are echoed.

    The actual or preflight request is rejected if any of the origins from the request is not allowed.

    Default: HttpOriginRange.*

    See also

    Access-Control-Allow-Origin

  6. abstract def exposedHeaders: Seq[String]

    List of headers (other than simple response headers) that browsers are allowed to access.

    List of headers (other than simple response headers) that browsers are allowed to access. If not empty, this list is returned as part of the Access-Control-Expose-Headers header in the actual response.

    Default: Seq.empty

    See also

    Access-Control-Expose-Headers

    Simple response headers

  7. abstract def maxAge: Option[Long]

    When set, the amount of seconds the browser is allowed to cache the results of a preflight request.

    When set, the amount of seconds the browser is allowed to cache the results of a preflight request. This value is returned as part of the Access-Control-Max-Age preflight response header. If None, the header is not added to the preflight response.

    Default: Some(30 * 60)

    See also

    Access-Control-Max-Age

  8. abstract def withAllowCredentials(newValue: Boolean): javadsl.settings.CorsSettings
    Definition Classes
    CorsSettings
  9. abstract def withAllowGenericHttpRequests(newValue: Boolean): javadsl.settings.CorsSettings
    Definition Classes
    CorsSettings
  10. abstract def withAllowedHeaders(newValue: HttpHeaderRange): javadsl.settings.CorsSettings
    Definition Classes
    CorsSettings
  11. abstract def withAllowedMethods(newValue: Iterable[HttpMethod]): javadsl.settings.CorsSettings
    Definition Classes
    CorsSettings
  12. abstract def withAllowedOrigins(newValue: HttpOriginRange): javadsl.settings.CorsSettings
    Definition Classes
    CorsSettings
  13. abstract def withExposedHeaders(newValue: Iterable[String]): javadsl.settings.CorsSettings
    Definition Classes
    CorsSettings
  14. abstract def withMaxAge(newValue: Optional[Long]): javadsl.settings.CorsSettings
    Definition Classes
    CorsSettings

Concrete Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  5. def clone(): AnyRef
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @native() @throws( ... )
  6. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  7. def equals(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  8. def finalize(): Unit
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  9. def getAllowCredentials: Boolean
    Definition Classes
    CorsSettingsCorsSettings
  10. def getAllowGenericHttpRequests: Boolean
    Definition Classes
    CorsSettingsCorsSettings
  11. def getAllowedHeaders: HttpHeaderRange
    Definition Classes
    CorsSettingsCorsSettings
  12. def getAllowedMethods: List[HttpMethod]
    Definition Classes
    CorsSettingsCorsSettings
  13. def getAllowedOrigins: HttpOriginRange
    Definition Classes
    CorsSettingsCorsSettings
  14. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  15. def getExposedHeaders: List[String]
    Definition Classes
    CorsSettingsCorsSettings
  16. def getMaxAge: Optional[Long]
    Definition Classes
    CorsSettingsCorsSettings
  17. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  18. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  19. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  20. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  21. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  22. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  23. def toString(): String
    Definition Classes
    AnyRef → Any
  24. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  25. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  26. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @throws( ... )

Inherited from AnyRef

Inherited from Any

Ungrouped