public final class BeanMapHelp<T> extends Object implements BeanCollectionHelp<T>
| Constructor and Description |
|---|
BeanMapHelp(BeanDescriptor<T> targetDescriptor,
String mapKey)
When created for a given query that will return a map.
|
BeanMapHelp(BeanPropertyAssocMany<T> many) |
| Modifier and Type | Method and Description |
|---|---|
void |
add(BeanCollection<?> collection,
Object bean)
Internal add bypassing any modify listening.
|
Object |
createEmpty(boolean vanilla)
Create an empty collection of the correct type.
|
BeanCollection<T> |
createReference(Object parentBean,
String propertyName)
Create a lazy loading proxy for a List Set or Map.
|
BeanCollectionAdd |
getBeanCollectionAdd(Object bc,
String mapKey)
Return the mechanism to add beans to the underlying collection.
|
Iterator<?> |
getIterator(Object collection)
Return an iterator of the values.
|
void |
jsonWrite(WriteJsonContext ctx,
String name,
Object collection,
boolean explicitInclude)
Write the collection out as json.
|
void |
refresh(BeanCollection<?> bc,
Object parentBean)
Apply the new refreshed BeanCollection to the appropriate property of the parent bean.
|
void |
refresh(EbeanServer server,
Query<?> query,
Transaction t,
Object parentBean)
Refresh the List Set or Map.
|
void |
setLoader(BeanCollectionLoader loader)
Set the EbeanServer that owns the configuration.
|
public BeanMapHelp(BeanDescriptor<T> targetDescriptor, String mapKey)
public BeanMapHelp(BeanPropertyAssocMany<T> many)
public Iterator<?> getIterator(Object collection)
getIterator in interface BeanCollectionHelp<T>public void setLoader(BeanCollectionLoader loader)
BeanCollectionHelpsetLoader in interface BeanCollectionHelp<T>public BeanCollectionAdd getBeanCollectionAdd(Object bc, String mapKey)
BeanCollectionHelpFor Map's this needs to take the mapKey.
getBeanCollectionAdd in interface BeanCollectionHelp<T>public Object createEmpty(boolean vanilla)
BeanCollectionHelpcreateEmpty in interface BeanCollectionHelp<T>public void add(BeanCollection<?> collection, Object bean)
add in interface BeanCollectionHelp<T>public BeanCollection<T> createReference(Object parentBean, String propertyName)
BeanCollectionHelpcreateReference in interface BeanCollectionHelp<T>public void refresh(EbeanServer server, Query<?> query, Transaction t, Object parentBean)
BeanCollectionHelprefresh in interface BeanCollectionHelp<T>public void refresh(BeanCollection<?> bc, Object parentBean)
BeanCollectionHelprefresh in interface BeanCollectionHelp<T>public void jsonWrite(WriteJsonContext ctx, String name, Object collection, boolean explicitInclude)
BeanCollectionHelpjsonWrite in interface BeanCollectionHelp<T>Copyright © 2014. All Rights Reserved.