Codota Logo
RequestBuilderBase.lazyInitCookies
Code IndexAdd Codota to your IDE (free)

How to use
lazyInitCookies
method
in
org.asynchttpclient.RequestBuilderBase

Best Java code snippets using org.asynchttpclient.RequestBuilderBase.lazyInitCookies (Showing top 4 results out of 315)

  • Common ways to obtain RequestBuilderBase
private void myMethod () {
RequestBuilderBase r =
  • Codota IconRequestBuilder requestBuilder;String str;requestBuilder.setUrl(str)
  • Codota IconRequestBuilder requestBuilder;BodyGenerator bodyGenerator;requestBuilder.setBody(bodyGenerator)
  • Codota IconBoundRequestBuilder boundRequestBuilder;String str;boundRequestBuilder.setBody(str)
  • Smart code suggestions by Codota
}
origin: AsyncHttpClient/async-http-client

public T addCookie(Cookie cookie) {
 lazyInitCookies();
 this.cookies.add(cookie);
 return asDerivedType();
}
origin: AsyncHttpClient/async-http-client

/**
 * Add/replace a cookie based on its name
 * @param cookie the new cookie
 * @return this
 */
public T addOrReplaceCookie(Cookie cookie) {
 String cookieKey = cookie.name();
 boolean replace = false;
 int index = 0;
 lazyInitCookies();
 for (Cookie c : this.cookies) {
  if (c.name().equals(cookieKey)) {
   replace = true;
   break;
  }
  index++;
 }
 if (replace)
  this.cookies.set(index, cookie);
 else
  this.cookies.add(cookie);
 return asDerivedType();
}
origin: org.asynchttpclient/async-http-client-api

public T addCookie(Cookie cookie) {
  lazyInitCookies();
  request.cookies.add(cookie);
  return derived.cast(this);
}
origin: org.asynchttpclient/async-http-client-api

public T addOrReplaceCookie(Cookie cookie) {
  String cookieKey = cookie.getName();
  boolean replace = false;
  int index = 0;
  lazyInitCookies();
  for (Cookie c : request.cookies) {
    if (c.getName().equals(cookieKey)) {
      replace = true;
      break;
    }
    index++;
  }
  if (replace)
    request.cookies.set(index, cookie);
  else
    request.cookies.add(cookie);
  return derived.cast(this);
}

org.asynchttpclientRequestBuilderBaselazyInitCookies

Popular methods of RequestBuilderBase

  • setHeader
  • executeSignatureCalculator
  • resetBody
  • resetFormParams
  • resetMultipartData
  • resetNonMultipartData
  • setBody
  • setFormParams
  • setQueryParams
  • setUri
  • addHeader
  • asDerivedType
  • addHeader,
  • asDerivedType,
  • build,
  • clearHeaders,
  • computeFinalUri,
  • computeRequestCharset,
  • computeRequestLength,
  • computeUri,
  • map2ParamList

Popular in Java

  • Start an intent from android
  • getExternalFilesDir (Context)
  • setRequestProperty (URLConnection)
  • getSystemService (Context)
  • FlowLayout (java.awt)
    A flow layout arranges components in a left-to-right flow, much like lines of text in a paragraph. F
  • BufferedWriter (java.io)
    Wraps an existing Writer and buffers the output. Expensive interaction with the underlying reader is
  • KeyStore (java.security)
    This class represents an in-memory collection of keys and certificates. It manages two types of entr
  • Deque (java.util)
    A linear collection that supports element insertion and removal at both ends. The name deque is shor
  • Annotation (javassist.bytecode.annotation)
    The annotation structure.An instance of this class is returned bygetAnnotations() in AnnotationsAttr
  • Base64 (org.apache.commons.codec.binary)
    Provides Base64 encoding and decoding as defined by RFC 2045.This class implements section 6.8. Base
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now