통합 검색 서비스로부터 응답 수신
AppContentManager 메소드를 사용하여 콘텐츠를 조작할 때 AppContentListener 인터페이스를 구현하는 클래스를 지정해야 합니다. 통합 검색 서비스는 요청을 처리한 후에 요청한 작업에 해당하는 AppContentListener 메소드에 알립니다.
각 AppContentManager 메소드에는 작업의 영향을 받은 객체 수를 알려 주는 매개 변수가 있습니다. 작업이 실패하는 경우 매개 변수의 값은 0입니다.
코드 샘플: AppContentListener 인터페이스 구현
public class MyListener implements AppContentListener {
public void onDeleteComplete(int delCount) {
// Action to take after records deleted.
}
public void onInsertComplete(int insertCount) {
// Action to take after new records inserted.
}
public void onUpdateComplete(int updCount) {
// Action to take after records updated.
}
}
다음 주제: 콘텐츠 저장소에서 데이터 제거
이전 주제: 데이터 변경 사항에 대해 통합 검색 서비스에 알림