Codota Logo
LinkDelegate.<init>
Code IndexAdd Codota to your IDE (free)

How to use
org.jboss.resteasy.plugins.delegates.LinkDelegate
constructor

Best Java code snippets using org.jboss.resteasy.plugins.delegates.LinkDelegate.<init> (Showing top 6 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
StringBuilder s =
  • Codota Iconnew StringBuilder()
  • Codota Iconnew StringBuilder(32)
  • Codota IconString str;new StringBuilder(str)
  • Smart code suggestions by Codota
}
origin: resteasy/Resteasy

addHeaderDelegateIfAbsent(Locale.class, new LocaleDelegate());
addHeaderDelegateIfAbsent(LinkHeader.class, new LinkHeaderDelegate());
addHeaderDelegateIfAbsent(javax.ws.rs.core.Link.class, new LinkDelegate());
addHeaderDelegateIfAbsent(Date.class, new DateDelegate());
origin: org.w3/ldp-testsuite

  @Override
  protected boolean matchesSafely(String item) {
    return expected.equals(new LinkDelegate().fromString(item));
  }
};
origin: org.jboss.resteasy/resteasy-core

addHeaderDelegateIfAbsent(Locale.class, new LocaleDelegate());
addHeaderDelegateIfAbsent(LinkHeader.class, new LinkHeaderDelegate());
addHeaderDelegateIfAbsent(javax.ws.rs.core.Link.class, new LinkDelegate());
addHeaderDelegateIfAbsent(Date.class, new DateDelegate());
origin: org.w3/ldp-testsuite

for (Header linkHeader : linkHeaders) {
  for (String s : splitLinks(linkHeader)) {
    Link nextLink = new LinkDelegate().fromString(s);
    if (relation.equals(nextLink.getRel())) {
      String actualLinkUri = resolveIfRelative(requestUri, nextLink.getUri());
origin: org.jboss.resteasy/resteasy-jaxrs-20

addHeaderDelegate(Locale.class, new LocaleDelegate());
addHeaderDelegate(LinkHeader.class, new LinkHeaderDelegate());
addHeaderDelegate(javax.ws.rs.core.Link.class, new LinkDelegate());
addHeaderDelegate(Date.class, new DateDelegate());
origin: org.w3/ldp-testsuite

/**
 * Gets the first link from {@code response} with link relation {@code rel}.
 * Resolves relative URIs against the request URI if necessary.
 *
 * @param linkContext
 *            the context of the Link (usually the request URI, but can be
 *            changed with an anchor parameter)
 * @param relation
 *            the expected link relation
 * @param requestUri
 *            the HTTP request URI (for determing a Link's context and
 *            resolving relative URIs)
 * @param response
 *            the HTTP response
 * @return the first link or {@code null} if none was found
 * @see <a href="http://tools.ietf.org/html/rfc5988">RFC 5988</a>
 */
protected String getFirstLinkForRelation(String linkContext, String relation, String requestUri, Response response) {
  List<Header> linkHeaders = response.getHeaders().getList(LINK);
  for (Header header : linkHeaders) {
    for (String s : splitLinks(header)) {
      Link l = new LinkDelegate().fromString(s);
      if (relation.equals(l.getRel()) &&
          linkMatchesContext(linkContext, requestUri, l)) {
        return resolveIfRelative(requestUri, l.getUri());
      }
    }
  }
  return null;
}
org.jboss.resteasy.plugins.delegatesLinkDelegate<init>

Popular methods of LinkDelegate

  • fromString

Popular in Java

  • Start an intent from android
  • addToBackStack (FragmentTransaction)
  • getContentResolver (Context)
  • compareTo (BigDecimal)
    Compares this BigDecimal with the specified BigDecimal. Two BigDecimal objects that are equal in val
  • OutputStream (java.io)
    A writable sink for bytes.Most clients will use output streams that write data to the file system (
  • UnknownHostException (java.net)
    Thrown when a hostname can not be resolved.
  • ArrayList (java.util)
    Resizable-array implementation of the List interface. Implements all optional list operations, and p
  • Calendar (java.util)
    Calendar is an abstract base class for converting between a Date object and a set of integer fields
  • Executor (java.util.concurrent)
    An object that executes submitted Runnable tasks. This interface provides a way of decoupling task s
  • LogFactory (org.apache.commons.logging)
    A minimal incarnation of Apache Commons Logging's LogFactory API, providing just the common Log look
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