Package org.springframework.hateoas

Examples of org.springframework.hateoas.ExposesResourceFor


  }

  private void registerControllerClass(Class<?> controllerType) {

    Assert.notNull(controllerType, "Controller type must nor be null!");
    ExposesResourceFor annotation = AnnotationUtils.findAnnotation(controllerType, ExposesResourceFor.class);

    if (annotation != null) {
      entityToController.put(annotation.value(), controllerType);
    } else {
      throw new IllegalArgumentException(String.format("Controller %s must be annotated with @ExposesResourceFor!",
          controllerType.getName()));
    }
  }
View Full Code Here


  public ControllerRelProvider(Class<?> controller, PluginRegistry<RelProvider, Class<?>> providers) {

    Assert.notNull(controller);

    ExposesResourceFor annotation = AnnotationUtils.findAnnotation(controller, ExposesResourceFor.class);
    Assert.notNull(annotation);

    this.controllerType = controller;
    this.entityType = annotation.value();
    this.providers = providers;
  }
View Full Code Here

TOP

Related Classes of org.springframework.hateoas.ExposesResourceFor

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.