Object/Trait

io.scalajs.npm.toughcookie

ToughCookie

Related Docs: trait ToughCookie | package toughcookie

Permalink

object ToughCookie extends Object with ToughCookie

Annotations
@native() @JSImport( "tough-cookie" , JSImport.Namespace )
Linear Supertypes
ToughCookie, Object, Any, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. ToughCookie
  2. ToughCookie
  3. Object
  4. Any
  5. AnyRef
  6. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  5. def canonicalDomain(str: String): String

    Permalink

    Transforms a domain-name into a canonical domain-name.

    Transforms a domain-name into a canonical domain-name. The canonical domain-name is a trimmed, lowercased, stripped-of-leading-dot and optionally punycode-encoded domain-name (Section 5.1.2 of RFC6265). For the most part, this function is idempotent (can be run again on its output without ill effects).

    str

    the domain string

    returns

    the canonical domain

    Definition Classes
    ToughCookie
  6. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  7. def cookieCompare(a: Cookie, b: Cookie): Boolean

    Permalink

    For use with .sort(), sorts a list of cookies into the recommended order given in the RFC (Section 5.4 step 2).

    For use with .sort(), sorts a list of cookies into the recommended order given in the RFC (Section 5.4 step 2). The sort algorithm is, in order of precedence:

    • Longest .path
    • oldest .creation (which has a 1ms precision, same as Date)
    • lowest .creationIndex (to get beyond the 1ms precision)
    Definition Classes
    ToughCookie
  8. def defaultPath(path: String): String

    Permalink

    Given a current request/response path, gives the Path appropriate for storing in a cookie.

    Given a current request/response path, gives the Path appropriate for storing in a cookie. This is basically the "directory" of a "file" in the path, but is specified by Section 5.1.4 of the RFC.

    The path parameter MUST be only the pathname part of a URI (i.e. excludes the hostname, query, fragment, etc.). This is the .pathname property of node's uri.parse() output.

    Definition Classes
    ToughCookie
  9. def domainMatch(str: String, domStr: String, canonicalize: Boolean = js.native): Boolean

    Permalink

    Answers "does this real domain match the domain in a cookie?".

    Answers "does this real domain match the domain in a cookie?". The str is the "current" domain-name and the domStr is the "cookie" domain-name. Matches according to RFC6265 Section 5.1.3, but it helps to think of it as a "suffix match".

    The canonicalize parameter will run the other two paramters through canonicalDomain or not.

    Definition Classes
    ToughCookie
  10. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  11. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  12. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  13. def formatDate(date: Date): String

    Permalink

    Format a Date into a RFC1123 string (the RFC6265-recommended format).

    Format a Date into a RFC1123 string (the RFC6265-recommended format).

    date

    the given js.Date

    returns

    the date-formatted string

    Definition Classes
    ToughCookie
  14. def fromJSON(string: String): Any

    Permalink

    Alias for Cookie.fromJSON(string)

    Alias for Cookie.fromJSON(string)

    Definition Classes
    ToughCookie
  15. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  16. def getPublicSuffix(hostname: String): String

    Permalink

    Returns the public suffix of this hostname.

    Returns the public suffix of this hostname. The public suffix is the shortest domain-name upon which a cookie can be set. Returns null if the hostname cannot have cookies set for it.

    For example: www.example.com and www.subdomain.example.com both have public suffix example.com.

    For further information, see http://publicsuffix.org/. This module derives its list from that site.

    Definition Classes
    ToughCookie
  17. def hasOwnProperty(v: String): Boolean

    Permalink
    Definition Classes
    Object
  18. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  19. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  20. def isPrototypeOf(v: Object): Boolean

    Permalink
    Definition Classes
    Object
  21. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  22. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  23. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  24. def parse(cookieString: String, options: RawOptions = js.native): Cookie

    Permalink

    Alias for Cookie.parse(cookieString[, options])

    Alias for Cookie.parse(cookieString[, options])

    cookieString

    the given cookie string

    options

    the parsing options

    Definition Classes
    ToughCookie
  25. def parseDate(string: String): Date

    Permalink

    Parse a cookie date string into a Date.

    Parse a cookie date string into a Date. Parses according to RFC6265 Section 5.1.1, not Date.parse().

    string

    the given date string

    returns

    the js.Date

    Definition Classes
    ToughCookie
  26. def pathMatch(reqPath: String, cookiePath: String): Boolean

    Permalink

    Answers "does the request-path path-match a given cookie-path?" as per RFC6265 Section 5.1.4.

    Answers "does the request-path path-match a given cookie-path?" as per RFC6265 Section 5.1.4. Returns a boolean.

    This is essentially a prefix-match where cookiePath is a prefix of reqPath.

    Definition Classes
    ToughCookie
  27. def permuteDomain(domain: String): Array[String]

    Permalink

    Generates a list of all possible domains that domainMatch() the parameter.

    Generates a list of all possible domains that domainMatch() the parameter. May be handy for implementing cookie stores.

    Definition Classes
    ToughCookie
  28. def permutePath(path: String): Array[String]

    Permalink

    Generates a list of all possible paths that pathMatch() the parameter.

    Generates a list of all possible paths that pathMatch() the parameter. May be handy for implementing cookie stores.

    Definition Classes
    ToughCookie
  29. def propertyIsEnumerable(v: String): Boolean

    Permalink
    Definition Classes
    Object
  30. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  31. def toLocaleString(): String

    Permalink
    Definition Classes
    Object
  32. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  33. def valueOf(): Any

    Permalink
    Definition Classes
    Object
  34. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  35. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  36. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from ToughCookie

Inherited from Object

Inherited from Any

Inherited from AnyRef

Inherited from Any

Ungrouped