package incheon.sgp.rst.service;

import java.util.List;
import java.util.Map;

/**
 * 공통 검색 서비스 인터페이스
 * 대장검색과 시설물검색에서 공통으로 사용되는 기본 CRUD 메서드들을 정의
 * 
 * @author incheon-geo-platform
 * @since 2025-08-06
 */
public interface RstBaseSearchService {
    
    /**
     * 검색 조건에 따른 목록 조회
     * 
     * @param requestVO 검색 조건을 담은 요청 VO
     * @return 검색 결과 목록
     * @throws Exception 조회 중 발생할 수 있는 예외
     */
    List<?> selectList(Object requestVO) throws Exception;
    
    /**
     * 검색 조건에 따른 목록 총 개수 조회
     * @param requestVO 검색 조건을 담은 요청 VO
     * @return 총 개수
     * @throws Exception 조회 중 발생할 수 있는 예외
     */
    int selectListTotalCount(Object requestVO) throws Exception;
    
    /**
     * 상세 정보 조회
     * 
     * @param typeId 검색 대상 타입 ID
     * @param requestModel 조회 조건을 담은 요청 Model
     * @return 상세 정보
     * @throws Exception 조회 중 발생할 수 있는 예외
     */
    Object selectDetail(String typeId, Object requestModel) throws Exception;
    
    /**
     * 정보 등록
     * 
     * @param requestModel 등록할 정보를 담은 요청 Model
     * @return 등록된 정보
     * @throws Exception 등록 중 발생할 수 있는 예외
     */
    Object insert(Object requestModel) throws Exception;
    
    /**
     * 정보 수정
     * 
     * @param requestModel 수정할 정보를 담은 요청 Model
     * @return 수정된 정보
     * @throws Exception 수정 중 발생할 수 있는 예외
     */
    Object update(Object requestModel) throws Exception;
    
    /**
     * 정보 삭제
     * 
     * @param requestModel 삭제할 정보를 담은 요청 Model
     * @return 삭제된 정보
     * @throws Exception 삭제 중 발생할 수 있는 예외
     */
    Object delete(Object requestModel) throws Exception;
    
    /**
     * 상세 패널 하위 탭
     * 
     * @param tabId
     * @param params
     * @return
     * @throws Exception
     */
    List<?> selectDetailTabList(String tabId, Map<String, Object> params) throws Exception;
} 