package com.ejie.ab79.dao.expedientes;

import java.util.List;

import com.ejie.ab79.model.expedientes.RelExpTer;
import com.ejie.x38.dto.TableRequestDto;
import com.ejie.x38.dto.TableRowDto;

/**
 * RelExpTerDao  
 * 
 *  
 */

public interface RelExpTerDao {

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

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

	/**
	 * Finds lista de participantes de la tabla RelExpTer
	 *
	 * @param relexpter
	 *            RelExpTer
	 * @return RelExpTer
	 */
	List<RelExpTer> findParticipantes(Integer idExpediente);

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

	/**
	 * Finds a List of rows in the RelExpTer table.
	 *
	 * @param relexpter
	 *            RelExpTer
	 * @param tableRequestDto
	 *            TableRequestDto
	 * @return List
	 */
	List<RelExpTer> findAll(RelExpTer relexpter, TableRequestDto tableRequestDto);

	/**
	 * Finds rows in the RelExpTer table using like.
	 *
	 * @param relexpter
	 *            RelExpTer
	 * @param tableRequestDto
	 *            TableRequestDto
	 * @param startsWith
	 *            Boolean
	 * @return List
	 */
	List<RelExpTer> findAllLike(RelExpTer relexpter, TableRequestDto tableRequestDto, Boolean startsWith);

	/*
	 * OPERACIONES RUP_TABLE
	 */

	/**
	 * Filter in the RelExpTer table.
	 *
	 * @param filterRelExpTer
	 *            RelExpTer
	 * @param tableRequestDto
	 *            TableRequestDto
	 * @param startsWith
	 *            Boolean
	 */
	void removeMultiple(RelExpTer filterRelExpTer, TableRequestDto tableRequestDto, Boolean startsWith);

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

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

	/**
	 * Reorder selection.
	 *
	 * @param filterRelExpTer
	 *            RelExpTer
	 * @param tableRequestDto
	 *            TableRequestDto
	 * @param startsWith
	 *            Boolean
	 * @return List<TableRowDto<RelExpTer>>
	 */
	List<TableRowDto<RelExpTer>> reorderSelection(RelExpTer filterRelExpTer, TableRequestDto tableRequestDto,
			Boolean startsWith);

	/**
	 * Searches in the Usuario table.
	 *
	 * @param filterRelExpTer
	 *            RelExpTer
	 * @param searchRelExpTer
	 *            RelExpTer
	 * @param tableRequestDto
	 *            TableRequestDto
	 * @param startsWith
	 *            Boolean
	 * @return List<TableRowDto<RelExpTer>>
	 */
	List<TableRowDto<RelExpTer>> search(RelExpTer filterRelExpTer, RelExpTer searchRelExpTer,
			TableRequestDto tableRequestDto, Boolean startsWith);

	/*
	 * OPERACIONES RUP_TABLE JERARQUIA
	 */

	/**
	 * Count rows in hierarchy
	 *
	 * @param filterRelExpTer
	 *            RelExpTer
	 * @param tableRequestDto
	 *            TableRequestDto
	 * @return Long
	 */
	Long findAllLikeCountJerarquia(RelExpTer filterRelExpTer, TableRequestDto tableRequestDto);

	/**
	 * Find dependent hierarchical rows
	 *
	 * @param filterRelExpTer
	 *            RelExpTer
	 * @param tableRequestDto
	 *            TableRequestDto
	 * @return List<TableRowDto<RelExpTer>>
	 */
	List<TableRowDto<RelExpTer>> findAllChild(RelExpTer filterRelExpTer, TableRequestDto tableRequestDto);

	/**
	 * Exporta Datos al clipBoard
	 *
	 */
	List<RelExpTer> getMultiple(RelExpTer filterRelExpTer, TableRequestDto tableRequestDto, Boolean startsWith);

	List<RelExpTer> findValorParticipant(Integer idExpediente);

	List<RelExpTer> findParticipantId(Integer idExpediente);

	void removeidTercero(Integer idTercero);

	RelExpTer updateSubtipo(RelExpTer relexpter);

}
