package com.ejie.ab63.dao;

import java.util.List;

import com.ejie.ab63.model.SalonComedor;
import com.ejie.x38.dto.JQGridRequestDto;
import com.ejie.x38.dto.JerarquiaDto;
import com.ejie.x38.dto.TableRowDto;

/**
 * Ab6327s00Dao  
 * 
 *  
 */

public interface SalonComedorDao {

	/**
	 * Inserts a single row in the Ab6327s00 table.
	 *
	 * @param ab6327s00
	 *            Ab6327s00
	 * @return Ab6327s00
	 */
	SalonComedor add(SalonComedor ab6327s00);

	/**
	 * Updates a single row in the Ab6327s00 table.
	 *
	 * @param ab6327s00
	 *            Ab6327s00
	 * @return Ab6327s00
	 */
	SalonComedor update(SalonComedor ab6327s00);

	/**
	 * Finds a single row in the Ab6327s00 table.
	 *
	 * @param ab6327s00
	 *            Ab6327s00
	 * @return Ab6327s00
	 */
	SalonComedor find(SalonComedor ab6327s00);

	/**
	 * Removes a single row in the Ab6327s00 table.
	 *
	 * @param ab6327s00
	 *            Ab6327s00
	 */
	void remove(SalonComedor ab6327s00);

	/**
	 * Finds a List of rows in the Ab6327s00 table.
	 *
	 * @param ab6327s00
	 *            Ab6327s00
	 * @param jqGridRequestDto
	 *            JQGridRequestDto
	 * @return List
	 */
	List<SalonComedor> findAll(SalonComedor ab6327s00, JQGridRequestDto jqGridRequestDto);

	/**
	 * Finds rows in the Ab6327s00 table using like.
	 *
	 * @param ab6327s00
	 *            Ab6327s00
	 * @param jqGridRequestDto
	 *            JQGridRequestDto
	 * @param startsWith
	 *            Boolean
	 * @return List
	 */
	List<SalonComedor> findAllLike(SalonComedor ab6327s00, JQGridRequestDto jqGridRequestDto, Boolean startsWith);

	/*
	 * OPERACIONES RUP_TABLE
	 */

	/**
	 * Filter in the Ab6327s00 table.
	 *
	 * @param filterAb6327s00
	 *            Ab6327s00
	 * @param jqGridRequestDto
	 *            JQGridRequestDto
	 * @param startsWith
	 *            Boolean
	 */
	void removeMultiple(SalonComedor filterAb6327s00, JQGridRequestDto jqGridRequestDto, Boolean startsWith);

	/**
	 * Counts rows in the Ab6327s00 table using like.
	 *
	 * @param ab6327s00
	 *            Ab6327s00
	 * @param startsWith
	 *            Boolean
	 * @return Long
	 */
	Long findAllLikeCount(SalonComedor ab6327s00, Boolean startsWith);

	/**
	 * Counts rows in the Ab6327s00 table.
	 *
	 * @param ab6327s00
	 *            Ab6327s00
	 * @return Long
	 */
	Long findAllCount(SalonComedor ab6327s00);

	/**
	 * Reorder selection.
	 *
	 * @param filterAb6327s00
	 *            Ab6327s00
	 * @param jqGridRequestDto
	 *            JQGridRequestDto
	 * @param startsWith
	 *            Boolean
	 * @return List<TableRowDto<Ab6327s00>>
	 */
	List<TableRowDto<SalonComedor>> reorderSelection(SalonComedor filterAb6327s00, JQGridRequestDto jqGridRequestDto,
			Boolean startsWith);

	/**
	 * Searches in the Usuario table.
	 *
	 * @param filterAb6327s00
	 *            Ab6327s00
	 * @param searchAb6327s00
	 *            Ab6327s00
	 * @param jqGridRequestDto
	 *            JQGridRequestDto
	 * @param startsWith
	 *            Boolean
	 * @return List<TableRowDto<Ab6327s00>>
	 */
	List<TableRowDto<SalonComedor>> search(SalonComedor filterAb6327s00, SalonComedor searchAb6327s00,
			JQGridRequestDto jqGridRequestDto, Boolean startsWith);

	/*
	 * OPERACIONES RUP_TABLE JERARQUIA
	 */

	/**
	 * Filter in the hierarchical Ab6327s00 table.
	 *
	 * @param filterAb6327s00
	 *            Ab6327s00
	 * @param jqGridRequestDto
	 *            JQGridRequestDto
	 * @return List<JerarquiaDto<Ab6327s00>>
	 */
	List<JerarquiaDto<SalonComedor>> findAllLikeJerarquia(SalonComedor filterAb6327s00,
			JQGridRequestDto jqGridRequestDto);

	/**
	 * Count rows in hierarchy
	 *
	 * @param filterAb6327s00
	 *            Ab6327s00
	 * @param jqGridRequestDto
	 *            JQGridRequestDto
	 * @return Long
	 */
	Long findAllLikeCountJerarquia(SalonComedor filterAb6327s00, JQGridRequestDto jqGridRequestDto);

	/**
	 * Find dependent hierarchical rows
	 *
	 * @param filterAb6327s00
	 *            Ab6327s00
	 * @param jqGridRequestDto
	 *            JQGridRequestDto
	 * @return List<TableRowDto<Ab6327s00>>
	 */
	List<TableRowDto<SalonComedor>> findAllChild(SalonComedor filterAb6327s00, JQGridRequestDto jqGridRequestDto);

	Long getTotalSalonesByIdEst(Integer idEstablecimiento);

	Long getTotalSalonesComedorByIdEst(Integer idEstablecimiento);

	Long getTotalComedoresByIdEst(Integer idEstablecimiento);

}
