All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.molgenis.data.EntityReferenceCreator Maven / Gradle / Ivy

There is a newer version: 8.4.5
Show newest version
package org.molgenis.data;

import org.molgenis.data.meta.model.EntityType;

public interface EntityReferenceCreator {
  /**
   * Get an instance, whose state may be lazily fetched. If the requested instance does not exist in
   * the repository, an UnknownEntityException is thrown when the instance state is
   * first accessed.
   *
   * @param entityType entity meta data
   * @param id entity identifier
   * @return entity
   */
  Entity getReference(EntityType entityType, Object id);

  /**
   * Get instances, whose state may be lazily fetched. If a requested instance does not exist in the
   * repository, an UnknownEntityException is thrown when the instance state is first
   * accessed.
   *
   * @param entityType entity meta data
   * @param ids entity identifiers
   * @return entities
   */
  Iterable getReferences(EntityType entityType, Iterable ids);
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy