package com.ejie.ab61.dao.inicioOficioExp;

import java.util.List;

import com.ejie.ab61.model.inicioOficioExp.RelExpOriDes;
import com.ejie.x38.dto.JQGridRequestDto;
import com.ejie.x38.dto.JerarquiaDto;
import com.ejie.x38.dto.TableRowDto;

/**
 * RelExpOriDesDao  
 * 
 *  
 */

public interface RelExpOriDesDao {

	/**
	 * Inserts a single row in the RelExpOriDes table.
	 *
	 * @param relexporides
	 *            RelExpOriDes
	 * @return RelExpOriDes
	 */
	RelExpOriDes add(RelExpOriDes relexporides);

	/**
	 * Updates a single row in the RelExpOriDes table.
	 *
	 * @param relexporides
	 *            RelExpOriDes
	 * @return RelExpOriDes
	 */
	RelExpOriDes update(RelExpOriDes relexporides);

	/**
	 * Finds a single row in the RelExpOriDes table.
	 *
	 * @param relexporides
	 *            RelExpOriDes
	 * @return RelExpOriDes
	 */
	RelExpOriDes find(RelExpOriDes relexporides);

	/**
	 * Removes a single row in the RelExpOriDes table.
	 *
	 * @param relexporides
	 *            RelExpOriDes
	 */
	void remove(RelExpOriDes relexporides);

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

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

	/*
	 * OPERACIONES RUP_TABLE
	 */

	/**
	 * Filter in the RelExpOriDes table.
	 *
	 * @param filterRelExpOriDes
	 *            RelExpOriDes
	 * @param jqGridRequestDto
	 *            JQGridRequestDto
	 * @param startsWith
	 *            Boolean
	 */
	void removeMultiple(RelExpOriDes filterRelExpOriDes, JQGridRequestDto jqGridRequestDto, Boolean startsWith);

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

	/**
	 * Counts rows in the RelExpOriDes table.
	 *
	 * @param relexporides
	 *            RelExpOriDes
	 * @return Long
	 */
	Long findAllCount(RelExpOriDes relexporides);

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

	/**
	 * Searches in the Usuario table.
	 *
	 * @param filterRelExpOriDes
	 *            RelExpOriDes
	 * @param searchRelExpOriDes
	 *            RelExpOriDes
	 * @param jqGridRequestDto
	 *            JQGridRequestDto
	 * @param startsWith
	 *            Boolean
	 * @return List<TableRowDto<RelExpOriDes>>
	 */
	List<TableRowDto<RelExpOriDes>> search(RelExpOriDes filterRelExpOriDes, RelExpOriDes searchRelExpOriDes,
			JQGridRequestDto jqGridRequestDto, Boolean startsWith);

	/*
	 * OPERACIONES RUP_TABLE JERARQUIA
	 */

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

	/**
	 * Count rows in hierarchy
	 *
	 * @param filterRelExpOriDes
	 *            RelExpOriDes
	 * @param jqGridRequestDto
	 *            JQGridRequestDto
	 * @return Long
	 */
	Long findAllLikeCountJerarquia(RelExpOriDes filterRelExpOriDes, JQGridRequestDto jqGridRequestDto);

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

}
