Package com.rosivanyshyn.db.dao

# Interface ApartmentDAO

All Superinterfaces:
  `GenericDAO<Apartment>`

All Known Implementing Classes:
  `ApartmentDAOImpl`

public interface ApartmentDAO extends GenericDAO<Apartment>
Apartment DAO interface.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `ArrayList<Apartment>`
  `getUniqueApartmentsWhichAreBookedWithDynamicQuery(Connection con, String secondQueryPart, Object... fields)`
  Get a list of unique booked apartments and apply to them query-builder part (Sorting, limits, etc.)
  `ArrayList<Apartment>`
  `getUniqueApartmentsWhichAreFree(Connection con, String secondQueryPart, Object... fields)`
  Get a list of unique free (not booked in the future), available (state is true) apartments
  `ArrayList<Apartment>`
  `searchApartments(Connection con, String value, int start, int total)`
  Get objects using direct search algorithms from respective table by relevance.

  ### Methods inherited from interface com.rosivanyshyn.db.dao.GenericDAO

  `countRowsInLastQuery, delete, get, getAll, getByField, getFew, getWithDynamicQuery, insert, update`

- ## Method Details

  - ### getUniqueApartmentsWhichAreBookedWithDynamicQuery

    ArrayList<Apartment> getUniqueApartmentsWhichAreBookedWithDynamicQuery(Connection con, String secondQueryPart, Object... fields)
    Get a list of unique booked apartments and apply to them query-builder part (Sorting, limits, etc.)
    Parameters:
      `con` - connection to database
      `secondQueryPart` - query builder string part
      `fields` - fields for insertion in query builder string part statement
    Returns:
      ArrayList result array

  - ### getUniqueApartmentsWhichAreFree

    ArrayList<Apartment> getUniqueApartmentsWhichAreFree(Connection con, String secondQueryPart, Object... fields)
    Get a list of unique free (not booked in the future), available (state is true) apartments
    Parameters:
      `con` - connection to database
      `secondQueryPart` - query builder string part
      `fields` - fields for insertion in query builder string part statement
    Returns:
      ArrayList result array

  - ### searchApartments

    ArrayList<Apartment> searchApartments(Connection con, String value, int start, int total)
    Get objects using direct search algorithms from respective table by relevance.
    Include tag functionality to regulate relevancy and result set
    Parameters:
      `con` - connection to database
      `value` - user value
    Returns:
      ArrayList result array