001package io.ebean.bean;
002
003import java.util.concurrent.locks.Lock;
004
005/**
006 * Loads a entity bean.
007 * <p>
008 * Typically invokes lazy loading for a single or batch of entity beans.
009 * </p>
010 */
011public interface BeanLoader {
012
013  /**
014   * Return the name of the associated Database.
015   */
016  String getName();
017
018  /**
019   * Invoke the lazy loading for this bean.
020   */
021  void loadBean(EntityBeanIntercept ebi);
022
023  /**
024   * Obtain a lock on the loader.
025   */
026  Lock lock();
027
028}