Share via


BaseInputConnection Class

Definition

Base class for implementors of the InputConnection interface, taking care of most of the common behavior for providing a connection to an Editable.

[Android.Runtime.Register("android/view/inputmethod/BaseInputConnection", DoNotGenerateAcw=true)]
public class BaseInputConnection : Java.Lang.Object, Android.Views.InputMethods.IInputConnection, IDisposable, Java.Interop.IJavaPeerable
[<Android.Runtime.Register("android/view/inputmethod/BaseInputConnection", DoNotGenerateAcw=true)>]
type BaseInputConnection = class
    inherit Object
    interface IInputConnection
    interface IJavaObject
    interface IDisposable
    interface IJavaPeerable
Inheritance
BaseInputConnection
Attributes
Implements

Remarks

Base class for implementors of the InputConnection interface, taking care of most of the common behavior for providing a connection to an Editable. Implementors of this class will want to be sure to implement #getEditable to provide access to their own editable object, and to refer to the documentation in InputConnection.

Java documentation for android.view.inputmethod.BaseInputConnection.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Constructors

BaseInputConnection(IntPtr, JniHandleOwnership)

A constructor used when creating managed representations of JNI objects; called by the runtime.

BaseInputConnection(View, Boolean)

Properties

Class

Returns the runtime class of this Object.

(Inherited from Object)
Editable

Return the target of edit operations.

Handle

The handle to the underlying Android instance.

(Inherited from Object)
Handler
JniIdentityHashCode (Inherited from Object)
JniPeerMembers
PeerReference (Inherited from Object)
ThresholdClass

This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.

ThresholdType

This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.

Methods

BeginBatchEdit()

Default implementation does nothing.

ClearMetaKeyStates(MetaKeyStates)

Default implementation uses MetaKeyKeyListener#clearMetaKeyState(long, int) MetaKeyKeyListener.clearMetaKeyState(long, int) to clear the state.

Clone()

Creates and returns a copy of this object.

(Inherited from Object)
CloseConnection()

Default implementation calls #finishComposingText() and setImeConsumesInput(false).

CommitCompletion(CompletionInfo)

Default implementation does nothing and returns false.

CommitContent(InputContentInfo, InputContentFlags, Bundle)

Default implementation which invokes View#performReceiveContent on the target view if the view View#getReceiveContentMimeTypes allows content insertion; otherwise returns false without any side effects.

CommitCorrection(CorrectionInfo)

Default implementation does nothing and returns false.

CommitText(ICharSequence, Int32)

Default implementation replaces any existing composing text with the given text.

CommitText(String, Int32)

Default implementation replaces any existing composing text with the given text.

DeleteSurroundingText(Int32, Int32)

The default implementation performs the deletion around the current selection position of the editable text.

DeleteSurroundingTextInCodePoints(Int32, Int32)

The default implementation performs the deletion around the current selection position of the editable text.

Dispose() (Inherited from Object)
Dispose(Boolean) (Inherited from Object)
EndBatchEdit()

Default implementation does nothing.

Equals(Object)

Indicates whether some other object is "equal to" this one.

(Inherited from Object)
FinishComposingText()

The default implementation removes the composing state from the current editable text.

GetComposingSpanEnd(ISpannable)

Return the end of the range of composing text, or -1 if there's no composing text.

GetComposingSpanStart(ISpannable)

Return the beginning of the range of composing text, or -1 if there's no composing text.

GetCursorCapsMode(CapitalizationMode)

The default implementation uses TextUtils.

GetExtractedText(ExtractedTextRequest, GetTextFlags)

The default implementation always returns null.

GetHashCode()

Returns a hash code value for the object.

(Inherited from Object)
GetSelectedText(GetTextFlags)

The default implementation returns the text currently selected, or null if none is selected.

GetSelectedTextFormatted(GetTextFlags)

The default implementation returns the text currently selected, or null if none is selected.

GetSurroundingText(Int32, Int32, Int32)

The default implementation returns the given amount of text around the current cursor position in the buffer.

GetTextAfterCursor(Int32, GetTextFlags)

The default implementation returns the given amount of text from the current cursor position in the buffer.

GetTextAfterCursorFormatted(Int32, GetTextFlags)

The default implementation returns the given amount of text from the current cursor position in the buffer.

GetTextBeforeCursor(Int32, GetTextFlags)

The default implementation returns the given amount of text from the current cursor position in the buffer.

GetTextBeforeCursorFormatted(Int32, GetTextFlags)

The default implementation returns the given amount of text from the current cursor position in the buffer.

JavaFinalize()

Called by the garbage collector on an object when garbage collection determines that there are no more references to the object.

(Inherited from Object)
Notify()

Wakes up a single thread that is waiting on this object's monitor.

(Inherited from Object)
NotifyAll()

Wakes up all threads that are waiting on this object's monitor.

(Inherited from Object)
PerformContextMenuAction(Int32)

The default implementation does nothing.

PerformEditorAction(ImeAction)

The default implementation turns this into the enter key.

PerformPrivateCommand(String, Bundle)

The default implementation does nothing.

RemoveComposingSpans(ISpannable)

Removes the composing spans from the given text if any.

ReplaceText(Int32, Int32, ICharSequence, Int32, TextAttribute)
ReplaceText(Int32, Int32, String, Int32, TextAttribute)
ReportFullscreenMode(Boolean)

Updates InputMethodManager with the current fullscreen mode.

RequestCursorUpdates(Int32)

The default implementation does nothing.

SendKeyEvent(KeyEvent)

Provides standard implementation for sending a key event to the window attached to the input connection's view.

SetComposingRegion(Int32, Int32)

Mark a certain region of text as composing text.

SetComposingSpans(ISpannable)

Removes the composing spans from the given text if any.

SetComposingText(ICharSequence, Int32)

The default implementation places the given text into the editable, replacing any existing composing text.

SetComposingText(String, Int32)

The default implementation places the given text into the editable, replacing any existing composing text.

SetHandle(IntPtr, JniHandleOwnership)

Sets the Handle property.

(Inherited from Object)
SetSelection(Int32, Int32)

The default implementation changes the selection position in the current editable text.

TakeSnapshot()

Default implementation that constructs TextSnapshot with information extracted from BaseInputConnection.

ToArray<T>() (Inherited from Object)
ToString()

Returns a string representation of the object.

(Inherited from Object)
UnregisterFromRuntime() (Inherited from Object)
Wait()

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>.

(Inherited from Object)
Wait(Int64, Int32)

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>, or until a certain amount of real time has elapsed.

(Inherited from Object)
Wait(Int64)

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>, or until a certain amount of real time has elapsed.

(Inherited from Object)

Explicit Interface Implementations

IJavaPeerable.Disposed() (Inherited from Object)
IJavaPeerable.DisposeUnlessReferenced() (Inherited from Object)
IJavaPeerable.Finalized() (Inherited from Object)
IJavaPeerable.JniManagedPeerState (Inherited from Object)
IJavaPeerable.SetJniIdentityHashCode(Int32) (Inherited from Object)
IJavaPeerable.SetJniManagedPeerState(JniManagedPeerStates) (Inherited from Object)
IJavaPeerable.SetPeerReference(JniObjectReference) (Inherited from Object)

Extension Methods

JavaCast<TResult>(IJavaObject)

Performs an Android runtime-checked type conversion.

CommitText(IInputConnection, String, Int32, TextAttribute)
CommitText(IInputConnection, String, Int32)
GetSelectedText(IInputConnection, GetTextFlags)
GetTextAfterCursor(IInputConnection, Int32, GetTextFlags)
GetTextBeforeCursor(IInputConnection, Int32, GetTextFlags)
ReplaceText(IInputConnection, Int32, Int32, String, Int32, TextAttribute)
SetComposingText(IInputConnection, String, Int32, TextAttribute)
SetComposingText(IInputConnection, String, Int32)
JavaCast<TResult>(IJavaObject)
GetJniTypeName(IJavaPeerable)

Applies to