Interface UnitDao

All Superinterfaces:
Dao
All Known Implementing Classes:
DefaultUnitDao

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

    • findUnitsByCode

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

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

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

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