io.lemonlabs.uri.inet.PublicSuffixSupport.scala Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of scala-uri_2.12 Show documentation
Show all versions of scala-uri_2.12 Show documentation
Simple scala library for building and parsing URIs
package io.lemonlabs.uri.inet
trait PublicSuffixSupport extends Product with Serializable {
/**
* Returns the longest public suffix for the host in this URI. Examples include:
* `com` for `www.example.com`
* `co.uk` for `www.example.co.uk`
*
* @return the longest public suffix for the host in this URI
*/
def publicSuffix: Option[String]
/**
* Returns all longest public suffixes for the host in this URI. Examples include:
* `com` for `www.example.com`
* `co.uk` and `uk` for `www.example.co.uk`
*
* @return all public suffixes for the host in this URI
*/
def publicSuffixes: Vector[String]
}