Class MetadataRepository

java.lang.Object
NTNU.IDATT1002.repository.AbstractRepository<Metadata,​java.lang.Long>
NTNU.IDATT1002.repository.MetadataRepository
All Implemented Interfaces:
Repository<Metadata,​java.lang.Long>

public class MetadataRepository
extends AbstractRepository<Metadata,​java.lang.Long>
Tag Repository. Implementation of AbstractRepository which supports regular Create, Read, Update and Delete operations.
Version:
1.0 22.03.20
Author:
Stian Mogen, Eirik Steira
See Also:
AbstractRepository
  • Constructor Details

  • Method Details

    • findOrCreate

      public java.util.Optional<Metadata> findOrCreate​(Metadata metadata)
      Retrieves a tag if found and creates it if not.
      Parameters:
      metadata - the tag to retrieve
      Returns:
      the tag if found, else the newly created one.