Interface UnitDao

  • All Superinterfaces:
    Dao
    All Known Implementing Classes:
    DefaultUnitDao

    public interface UnitDao
    extends Dao
    The UnitModel DAO.
    Spring Bean ID:
    unitDao
    • Method Detail

      • findUnitsByCode

        java.util.Set<UnitModel> findUnitsByCode​(java.lang.String code)
        Parameters:
        code - the UnitModel.CODE
        Returns:
        for the given code the UnitModel
        Throws:
        java.lang.IllegalArgumentException - if code is null.
      • findAllUnits

        java.util.Set<UnitModel> findAllUnits()
        Returns all Units.
        Returns:
        a set containing all units.
      • findAllUnitTypes

        java.util.Set<java.lang.String> findAllUnitTypes()
        Finds all unit types (e.g. 'weight', 'size' ).
        Returns:
        a set of type strings
      • findUnitsByUnitType

        java.util.Set<UnitModel> findUnitsByUnitType​(java.lang.String unitType)
        Finds all units that match specific unit type
        Parameters:
        unitType - unit type
        Returns:
        set of units that match unit type