com.basho.riak.client.convert.reflect
Class AnnotationInfo
java.lang.Object
com.basho.riak.client.convert.reflect.AnnotationInfo
public class AnnotationInfo
- extends Object
Class that contains the Riak annotated fields for an annotated class
- Author:
- russell
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AnnotationInfo
public AnnotationInfo(Field riakKeyField,
List<UsermetaField> usermetaItemFields,
Field usermetaMapField,
List<RiakIndexField> indexFields,
Field riakLinksField)
- Parameters:
riakKeyField
- usermetaItemFields
- usermetaMapField
-
hasRiakKey
public boolean hasRiakKey()
- Returns:
getRiakKey
public <T> String getRiakKey(T obj)
- Type Parameters:
T
- - Parameters:
obj
-
- Returns:
setRiakKey
public <T> void setRiakKey(T obj,
String key)
getUsermetaData
public <T> Map<String,String> getUsermetaData(T obj)
setUsermetaData
public <T> void setUsermetaData(Map<String,String> usermetaData,
T obj)
getIndexes
public <T> RiakIndexes getIndexes(T obj)
- Returns:
- a
RiakIndexes
made of the values of the RiakIndex
annotated fields
setIndexes
public <T> void setIndexes(RiakIndexes indexes,
T obj)
- TODO handle multi-value indexes with the same name
- Type Parameters:
T
- - Parameters:
indexes
- the RiakIndexes to copy to the domain objectobj
- the domain object to set indexes on
getLinks
public <T> Collection<RiakLink> getLinks(T obj)
setLinks
public <T> void setLinks(Collection<RiakLink> links,
T obj)
Copyright © 2012. All Rights Reserved.