Spring Hateoas

org.springframework.hateoas.core
Class DefaultRelProvider

java.lang.Object
  extended by org.springframework.hateoas.core.DefaultRelProvider
All Implemented Interfaces:
RelProvider, org.springframework.plugin.core.Plugin<Class<?>>
Direct Known Subclasses:
EvoInflectorRelProvider

public class DefaultRelProvider
extends Object
implements RelProvider

Default implementation of RelProvider to simply use the uncapitalized version of the given type's name as single resource rel as well as an appended List for the collection resource rel.

Author:
Oliver Gierke

Constructor Summary
DefaultRelProvider()
           
 
Method Summary
 String getCollectionResourceRelFor(Class<?> type)
           
 String getSingleResourceRelFor(Class<?> type)
           
 boolean supports(Class<?> delimiter)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultRelProvider

public DefaultRelProvider()
Method Detail

supports

public boolean supports(Class<?> delimiter)
Specified by:
supports in interface org.springframework.plugin.core.Plugin<Class<?>>

getCollectionResourceRelFor

public String getCollectionResourceRelFor(Class<?> type)
Specified by:
getCollectionResourceRelFor in interface RelProvider

getSingleResourceRelFor

public String getSingleResourceRelFor(Class<?> type)
Specified by:
getSingleResourceRelFor in interface RelProvider

Spring Hateoas

Copyright © 2012-2013 SpringSource, a division of VMware. All Rights Reserved.