Interface BaseImmutableService<O extends Identifiable>

All Superinterfaces:
BaseReadOnlyService<O>
All Known Subinterfaces:
AnalysisService<T>, AnnotationAssociationService, ArrayDesignService, AuditTrailService, BaseService<O>, BibliographicReferenceService, BioAssayDimensionService, BioAssayService, BioMaterialService, BioSequenceService, BlacklistedEntityService, BlatAssociationService, BlatResultService, CharacteristicService, CoexpressionAnalysisService, CompositeSequenceService, CompoundService, ContactService, DatabaseEntryService, DifferentialExpressionAnalysisService, ExperimentalDesignService, ExperimentalFactorService, ExpressionExperimentService, ExpressionExperimentSetService, ExpressionExperimentSubSetService, ExternalDatabaseService, FactorValueService, Gene2GOAssociationService, GeneDiffExMetaAnalysisService, GeneProductService, GeneService, GeneSetService, PrincipalComponentAnalysisService, ProtocolService, QuantitationTypeService, SecurableBaseImmutableService<C>, SecurableBaseService<C>, TaxonService
All Known Implementing Classes:
AbstractBulkExpressionDataVectorService, AbstractFilteringVoEnabledService, AbstractService, AbstractVoEnabledService, AnnotationAssociationServiceImpl, ArrayDesignServiceImpl, AuditTrailServiceImpl, BibliographicReferenceServiceImpl, BioAssayDimensionServiceImpl, BioAssayServiceImpl, BioMaterialServiceImpl, BioSequenceServiceImpl, BlacklistedEntityServiceImpl, BlatAssociationServiceImpl, BlatResultServiceImpl, CharacteristicServiceImpl, ChromosomeServiceImpl, CoexpressionAnalysisServiceImpl, CompositeSequenceServiceImpl, CompoundServiceImpl, ContactServiceImpl, DatabaseEntryServiceImpl, DifferentialExpressionAnalysisServiceImpl, DifferentialExpressionResultServiceImpl, ExperimentalDesignServiceImpl, ExperimentalFactorServiceImpl, ExpressionAnalysisResultSetServiceImpl, ExpressionExperimentServiceImpl, ExpressionExperimentSetServiceImpl, ExpressionExperimentSubSetServiceImpl, ExternalDatabaseServiceImpl, FactorValueServiceImpl, GeeqServiceImpl, Gene2GOAssociationServiceImpl, GeneDiffExMetaAnalysisServiceImpl, GeneProductServiceImpl, GeneServiceImpl, GeneSetServiceImpl, PrincipalComponentAnalysisServiceImpl, ProcessedExpressionDataVectorServiceImpl, ProtocolServiceImpl, QuantitationTypeServiceImpl, RawAndProcessedExpressionDataVectorServiceImpl, RawExpressionDataVectorServiceImpl, TaxonServiceImpl

public interface BaseImmutableService<O extends Identifiable> extends BaseReadOnlyService<O>
Base service class for an immutable entity.

Immutable entities can be created, deleted but never updated.

Author:
poirigui
  • Method Details

    • findOrCreate

      @CheckReturnValue O findOrCreate(O entity)
      Does a search for the entity in the persistent storage, and if not found, creates it.
      Parameters:
      entity - the entity to look for, and create if not found.
      Returns:
      the entity retrieved from the persistent storage, either found or created.
    • create

      Creates all the given entities in a persistent storage
      Parameters:
      entities - the entities to be created.
      Returns:
      collection of objects referencing the persistent instances of given entities.
    • create

      @CheckReturnValue O create(O entity)
      Creates the given entity in the persistent storage.
      Parameters:
      entity - the entity to be created.
      Returns:
      object referencing the persistent instance of the given entity.
    • remove

      void remove(Collection<O> entities)
      Removes all the given entities from persistent storage.
      Parameters:
      entities - the entities to be removed.
    • remove

      void remove(Long id)
      Removes the entity with given ID from the persistent storage.
      Parameters:
      id - the ID of entity to be removed.
    • remove

      void remove(O entity)
      Removes the given entity from the persistent storage.
      Parameters:
      entity - the entity to be removed.