Home | History | Annotate | Download | only in textservice
      1 /*
      2  * Copyright (C) 2011 The Android Open Source Project
      3  *
      4  * Licensed under the Apache License, Version 2.0 (the "License");
      5  * you may not use this file except in compliance with the License.
      6  * You may obtain a copy of the License at
      7  *
      8  *      http://www.apache.org/licenses/LICENSE-2.0
      9  *
     10  * Unless required by applicable law or agreed to in writing, software
     11  * distributed under the License is distributed on an "AS IS" BASIS,
     12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     13  * See the License for the specific language governing permissions and
     14  * limitations under the License.
     15  */
     16 
     17 package com.android.internal.textservice;
     18 
     19 import com.android.internal.textservice.ISpellCheckerServiceCallback;
     20 import com.android.internal.textservice.ISpellCheckerSession;
     21 import com.android.internal.textservice.ISpellCheckerSessionListener;
     22 
     23 import android.os.Bundle;
     24 
     25 /**
     26  * IPC channels from TextServicesManagerService to SpellCheckerService.
     27  * @hide
     28  */
     29 oneway interface ISpellCheckerService {
     30     /**
     31      * Called from the system when an application is requesting a new spell checker session.
     32      *
     33      * <p>Note: This is an internal protocol used by the system to establish spell checker sessions,
     34      * which is not guaranteed to be stable and is subject to change.</p>
     35      *
     36      * @param locale locale to be returned from
     37      *               {@link android.service.textservice.SpellCheckerService.Session#getLocale()}
     38      * @param listener IPC channel object to be used to implement
     39      *                 {@link android.service.textservice.SpellCheckerService.Session#onGetSuggestionsMultiple(TextInfo[], int, boolean)} and
     40      *                 {@link android.service.textservice.SpellCheckerService.Session#onGetSuggestions(TextInfo, int)}
     41      * @param bundle bundle to be returned from {@link android.service.textservice.SpellCheckerService.Session#getBundle()}
     42      * @param callback IPC channel to return the result to the caller in an asynchronous manner
     43      */
     44     void getISpellCheckerSession(
     45             String locale, ISpellCheckerSessionListener listener, in Bundle bundle,
     46             ISpellCheckerServiceCallback callback);
     47 }
     48