Tabnine Logo
CookieOrigin.getHost
Code IndexAdd Tabnine to your IDE (free)

How to use
getHost
method
in
org.apache.commons.httpclient.cookie.CookieOrigin

Best Java code snippets using org.apache.commons.httpclient.cookie.CookieOrigin.getHost (Showing top 10 results out of 315)

origin: commons-httpclient/commons-httpclient

/**
 * Match cookie domain attribute.
 */
public boolean match(final Cookie cookie, final CookieOrigin origin) {
  if (cookie == null) {
    throw new IllegalArgumentException("Cookie may not be null");
  }
  if (origin == null) {
    throw new IllegalArgumentException("Cookie origin may not be null");
  }
  String host = origin.getHost().toLowerCase();
  String cookieDomain = cookie.getDomain();
  // The effective host name MUST domain-match the Domain
  // attribute of the cookie.
  if (!domainMatch(host, cookieDomain)) {
    return false;
  }
  // effective host name minus domain must not contain any dots
  String effectiveHostWithoutDomain = host.substring(
      0, host.length() - cookieDomain.length());
  if (effectiveHostWithoutDomain.indexOf('.') != -1) {
    return false;
  }
  return true;
}
origin: commons-httpclient/commons-httpclient

  throw new IllegalArgumentException("Cookie origin may not be null");
String host = origin.getHost().toLowerCase();
if (cookie.getDomain() == null) {
  throw new MalformedCookieException("Invalid cookie state: " +
origin: org.apache.commons/com.springsource.org.apache.commons.httpclient

/**
 * Match cookie domain attribute.
 */
public boolean match(final Cookie cookie, final CookieOrigin origin) {
  if (cookie == null) {
    throw new IllegalArgumentException("Cookie may not be null");
  }
  if (origin == null) {
    throw new IllegalArgumentException("Cookie origin may not be null");
  }
  String host = origin.getHost().toLowerCase();
  String cookieDomain = cookie.getDomain();
  // The effective host name MUST domain-match the Domain
  // attribute of the cookie.
  if (!domainMatch(host, cookieDomain)) {
    return false;
  }
  // effective host name minus domain must not contain any dots
  String effectiveHostWithoutDomain = host.substring(
      0, host.length() - cookieDomain.length());
  if (effectiveHostWithoutDomain.indexOf('.') != -1) {
    return false;
  }
  return true;
}
origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.commons-httpclient

/**
 * Match cookie domain attribute.
 */
public boolean match(final Cookie cookie, final CookieOrigin origin) {
  if (cookie == null) {
    throw new IllegalArgumentException("Cookie may not be null");
  }
  if (origin == null) {
    throw new IllegalArgumentException("Cookie origin may not be null");
  }
  String host = origin.getHost().toLowerCase();
  String cookieDomain = cookie.getDomain();
  // The effective host name MUST domain-match the Domain
  // attribute of the cookie.
  if (!domainMatch(host, cookieDomain)) {
    return false;
  }
  // effective host name minus domain must not contain any dots
  String effectiveHostWithoutDomain = host.substring(
      0, host.length() - cookieDomain.length());
  if (effectiveHostWithoutDomain.indexOf('.') != -1) {
    return false;
  }
  return true;
}
origin: org.apache.commons/httpclient

/**
 * Match cookie domain attribute.
 */
public boolean match(final Cookie cookie, final CookieOrigin origin) {
  if (cookie == null) {
    throw new IllegalArgumentException("Cookie may not be null");
  }
  if (origin == null) {
    throw new IllegalArgumentException("Cookie origin may not be null");
  }
  String host = origin.getHost().toLowerCase();
  String cookieDomain = cookie.getDomain();
  // The effective host name MUST domain-match the Domain
  // attribute of the cookie.
  if (!domainMatch(host, cookieDomain)) {
    return false;
  }
  // effective host name minus domain must not contain any dots
  String effectiveHostWithoutDomain = host.substring(
      0, host.length() - cookieDomain.length());
  if (effectiveHostWithoutDomain.indexOf('.') != -1) {
    return false;
  }
  return true;
}
origin: org.wso2.commons-httpclient/commons-httpclient

/**
 * Match cookie domain attribute.
 */
public boolean match(final Cookie cookie, final CookieOrigin origin) {
  if (cookie == null) {
    throw new IllegalArgumentException("Cookie may not be null");
  }
  if (origin == null) {
    throw new IllegalArgumentException("Cookie origin may not be null");
  }
  String host = origin.getHost().toLowerCase();
  String cookieDomain = cookie.getDomain();
  // The effective host name MUST domain-match the Domain
  // attribute of the cookie.
  if (!domainMatch(host, cookieDomain)) {
    return false;
  }
  // effective host name minus domain must not contain any dots
  String effectiveHostWithoutDomain = host.substring(
      0, host.length() - cookieDomain.length());
  if (effectiveHostWithoutDomain.indexOf('.') != -1) {
    return false;
  }
  return true;
}
origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.commons-httpclient

  throw new IllegalArgumentException("Cookie origin may not be null");
String host = origin.getHost().toLowerCase();
if (cookie.getDomain() == null) {
  throw new MalformedCookieException("Invalid cookie state: " +
origin: org.wso2.commons-httpclient/commons-httpclient

  throw new IllegalArgumentException("Cookie origin may not be null");
String host = origin.getHost().toLowerCase();
if (cookie.getDomain() == null) {
  throw new MalformedCookieException("Invalid cookie state: " +
origin: org.apache.commons/com.springsource.org.apache.commons.httpclient

  throw new IllegalArgumentException("Cookie origin may not be null");
String host = origin.getHost().toLowerCase();
if (cookie.getDomain() == null) {
  throw new MalformedCookieException("Invalid cookie state: " +
origin: org.apache.commons/httpclient

  throw new IllegalArgumentException("Cookie origin may not be null");
String host = origin.getHost().toLowerCase();
if (cookie.getDomain() == null) {
  throw new MalformedCookieException("Invalid cookie state: " +
org.apache.commons.httpclient.cookieCookieOrigingetHost

Popular methods of CookieOrigin

  • <init>
  • getPath
  • getPort
  • isSecure

Popular in Java

  • Updating database using SQL prepared statement
  • scheduleAtFixedRate (Timer)
  • getSupportFragmentManager (FragmentActivity)
  • startActivity (Activity)
  • Proxy (java.net)
    This class represents proxy server settings. A created instance of Proxy stores a type and an addres
  • Path (java.nio.file)
  • Scanner (java.util)
    A parser that parses a text string of primitive types and strings with the help of regular expressio
  • ImageIO (javax.imageio)
  • Get (org.apache.hadoop.hbase.client)
    Used to perform Get operations on a single row. To get everything for a row, instantiate a Get objec
  • LoggerFactory (org.slf4j)
    The LoggerFactory is a utility class producing Loggers for various logging APIs, most notably for lo
  • From CI to AI: The AI layer in your organization
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now