Class BeanMapHelp<T>

java.lang.Object
io.ebeaninternal.server.deploy.BeanMapHelp<T>
All Implemented Interfaces:
BeanCollectionHelp<T>, CQueryCollectionAdd<T>
Direct Known Subclasses:
BeanMapHelpElement

public class BeanMapHelp<T> extends Object
Helper specifically for dealing with Maps.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    add(io.ebean.bean.BeanCollection<?> collection, io.ebean.bean.EntityBean bean, boolean withCheck)
    Add a bean to the List Set or Map.
    final io.ebean.bean.BeanCollection<T>
    createEmpty(io.ebean.bean.EntityBean ownerBean)
    Create an empty collection of the correct type.
    final io.ebean.bean.BeanCollection<T>
    Create an empty collection of the correct type without a parent bean.
    final Object
    Create and return an empty 'vanilla' collection that does not support lazy loading.
    final io.ebean.bean.BeanCollection<T>
    createReference(io.ebean.bean.EntityBean parentBean)
    Create a lazy loading proxy for a List Set or Map.
    final io.ebean.bean.BeanCollectionAdd
    Return the mechanism to add beans to the underlying collection.
    final void
    jsonWrite(SpiJsonWriter ctx, String name, Object collection, boolean explicitInclude)
    Write the collection out as json.
    final void
    refresh(io.ebean.bean.BeanCollection<?> bc, io.ebean.bean.EntityBean parentBean)
    Apply the new refreshed BeanCollection to the appropriate property of the parent bean.
    final void
    setLoader(io.ebean.bean.BeanCollectionLoader loader)
    Set the EbeanServer that owns the configuration.
    Return the underlying collection of beans.

    Methods inherited from class Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • getBeanCollectionAdd

      public final io.ebean.bean.BeanCollectionAdd getBeanCollectionAdd(Object bc, String mapKey)
      Description copied from interface: BeanCollectionHelp
      Return the mechanism to add beans to the underlying collection.

      For Map's this needs to take the mapKey.

    • createEmptyReference

      public final Object createEmptyReference()
      Description copied from interface: BeanCollectionHelp
      Create and return an empty 'vanilla' collection that does not support lazy loading.
    • createEmptyNoParent

      public final io.ebean.bean.BeanCollection<T> createEmptyNoParent()
      Description copied from interface: BeanCollectionHelp
      Create an empty collection of the correct type without a parent bean.
    • createEmpty

      public final io.ebean.bean.BeanCollection<T> createEmpty(io.ebean.bean.EntityBean ownerBean)
      Description copied from interface: BeanCollectionHelp
      Create an empty collection of the correct type.
    • add

      public void add(io.ebean.bean.BeanCollection<?> collection, io.ebean.bean.EntityBean bean, boolean withCheck)
      Description copied from interface: BeanCollectionHelp
      Add a bean to the List Set or Map.
      Specified by:
      add in interface BeanCollectionHelp<T>
      Specified by:
      add in interface CQueryCollectionAdd<T>
    • createReference

      public final io.ebean.bean.BeanCollection<T> createReference(io.ebean.bean.EntityBean parentBean)
      Description copied from interface: BeanCollectionHelp
      Create a lazy loading proxy for a List Set or Map.
    • refresh

      public final void refresh(io.ebean.bean.BeanCollection<?> bc, io.ebean.bean.EntityBean parentBean)
      Description copied from interface: BeanCollectionHelp
      Apply the new refreshed BeanCollection to the appropriate property of the parent bean.
    • jsonWrite

      public final void jsonWrite(SpiJsonWriter ctx, String name, Object collection, boolean explicitInclude) throws IOException
      Description copied from interface: BeanCollectionHelp
      Write the collection out as json.
      Throws:
      IOException
    • setLoader

      public final void setLoader(io.ebean.bean.BeanCollectionLoader loader)
      Description copied from interface: BeanCollectionHelp
      Set the EbeanServer that owns the configuration.
      Specified by:
      setLoader in interface BeanCollectionHelp<T>
    • underlying

      public final Collection underlying(Object value)
      Description copied from interface: BeanCollectionHelp
      Return the underlying collection of beans.
      Specified by:
      underlying in interface BeanCollectionHelp<T>