Package com.jayway.jaxrs.hateoas.support

Examples of com.jayway.jaxrs.hateoas.support.DefaultCollectionWrapperStrategy


  public HateoasApplication() {
    this(HateoasVerbosity.MAXIMUM);
  }

  public HateoasApplication(HateoasVerbosity verbosity) {
    this(new JavassistHateoasLinkInjector(), new DefaultCollectionWrapperStrategy(), verbosity);
  }
View Full Code Here


        this(HateoasVerbosity.MAXIMUM, packages);
    }

    public JerseyHateoasApplication(HateoasVerbosity verbosity,
                                    String... packages) {
        this(new JavassistHateoasLinkInjector(), new DefaultCollectionWrapperStrategy(), verbosity, packages);
    }
View Full Code Here

     * @param verbosity the verbosity level to use in the application
     * @param props properties to be passed to {@link PackagesResourceConfig} constructor
     */
    public JerseyHateoasApplication(HateoasVerbosity verbosity,
                                    Map<String, Object> props) {
        this(new JavassistHateoasLinkInjector(), new DefaultCollectionWrapperStrategy(), verbosity, props);
    }
View Full Code Here

                return (CollectionWrapperStrategy) impl.newInstance();
            } catch (Exception e) {
                throw new RuntimeException("Could not create instance of CollectionWrapperStrategy: " + implClass, e);
            }
        } else {
            return new DefaultCollectionWrapperStrategy();
        }
    }
View Full Code Here

    private CollectionWrapperStrategy getCollectionWrapperStrategy(ResourceConfig rc) {
        Object propertyValue = rc.getProperty(PROPERTY_COLLECTION_WRAPPER_STRATEGY);

        if (propertyValue == null) {
            logger.info("Using default CollectionWrapperStrategy");
            return new DefaultCollectionWrapperStrategy();
        } else {
            logger.info("Using {} as LinkInjector", propertyValue);
            try {
                return (CollectionWrapperStrategy) Class.forName((String) propertyValue).newInstance();
            } catch (Exception e) {
View Full Code Here

  public HateoasApplication() {
    this(HateoasVerbosity.MAXIMUM);
  }

  public HateoasApplication(HateoasVerbosity verbosity) {
    this(new StrategyBasedLinkInjector(), new DefaultCollectionWrapperStrategy(), verbosity);
  }
View Full Code Here

TOP

Related Classes of com.jayway.jaxrs.hateoas.support.DefaultCollectionWrapperStrategy

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.