Codota Logo
HeaderDecoratorPrecedence
Code IndexAdd Codota to your IDE (free)

How to use
HeaderDecoratorPrecedence
in
org.jboss.resteasy.annotations.interception

Best Java code snippets using org.jboss.resteasy.annotations.interception.HeaderDecoratorPrecedence (Showing top 3 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
ArrayList a =
  • Codota Iconnew ArrayList<String>()
  • Codota Iconnew ArrayList()
  • Codota Iconnew ArrayList<Object>()
  • Smart code suggestions by Codota
}
origin: com.codeablereason.restcompress.provider/rest-compress-lib

/**
 * Client interceptor to set HTTP headers to advertise that REST client can accept LZF encoding
 */
@Provider
@ClientInterceptor
@HeaderDecoratorPrecedence
public class AcceptLZFClientInterceptor {

  /**
   * Set headers to advertise ability to accept LZF compression  <p/>
   * Check if client response has HTTP header "Accept-Encoding" set: <p/>
   * <ul>   <li>- If none, set header to "lzf", if has a header, add lzf to the list</li></ul>
   * @param ctx Client execution context
   * @return Response with headers appended
   * @throws Exception
   */
  public ClientResponse execute(ClientExecutionContext ctx) throws Exception {
    String encoding = ctx.getRequest().getHeaders().getFirst(HttpHeaders.ACCEPT_ENCODING);
    if (encoding == null) {
      ctx.getRequest().header(HttpHeaders.ACCEPT_ENCODING, "lzf");
    } else {
      if (!encoding.contains("lzf")) {
        encoding += ", lzf";
        ctx.getRequest().header(HttpHeaders.ACCEPT_ENCODING, encoding);
      }
    }
    return ctx.proceed();
  }
}

origin: org.jboss.resteasy/resteasy-legacy

@HeaderDecoratorPrecedence
public class AcceptEncodingGZIPInterceptor implements ClientExecutionInterceptor
origin: org.jboss.resteasy/resteasy-jaxrs-20

@HeaderDecoratorPrecedence
@Deprecated
public class AcceptEncodingGZIPInterceptor implements ClientExecutionInterceptor
org.jboss.resteasy.annotations.interceptionHeaderDecoratorPrecedence

Most used methods

  • <init>

Popular in Java

  • Reactive rest calls using spring rest template
  • getContentResolver (Context)
  • notifyDataSetChanged (ArrayAdapter)
  • setScale (BigDecimal)
    Returns a BigDecimal whose scale is the specified value, and whose value is numerically equal to thi
  • FileNotFoundException (java.io)
    Thrown when a file specified by a program cannot be found.
  • PrintWriter (java.io)
    Prints formatted representations of objects to a text-output stream. This class implements all of th
  • ConcurrentHashMap (java.util.concurrent)
    A hash table supporting full concurrency of retrievals and adjustable expected concurrency for updat
  • ImageIO (javax.imageio)
  • JOptionPane (javax.swing)
  • Option (scala)
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