# Class TimedRecognitionCallback.Adapter

java.lang.Object
com.codename1.media.RecognitionCallback.Adapter
com.codename1.media.TimedRecognitionCallback.Adapter

All Implemented Interfaces:
  `RecognitionCallback, TimedRecognitionCallback`

Enclosing interface:
  `TimedRecognitionCallback`

public static class TimedRecognitionCallback.Adapter extends RecognitionCallback.Adapter implements TimedRecognitionCallback
No-op adapter. The timed overloads forward to the string-only overloads, so subclassing this preserves normal `RecognitionCallback` behaviour unless the timed methods are explicitly overridden.

- ## Nested Class Summary

  ### Nested classes/interfaces inherited from interface RecognitionCallback

  `RecognitionCallback.Adapter`

  ### Nested classes/interfaces inherited from interface TimedRecognitionCallback

  `TimedRecognitionCallback.Adapter`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `Adapter()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `onPartialResult(TranscriptionResult result)`
  Forwards partial timed results to the string-only partial callback.
  `void`
  `onResult(TranscriptionResult result, float confidence, String[] alternatives)`
  Forwards final timed results to the string-only result callback.

  ### Methods inherited from class RecognitionCallback.Adapter

  `onEnd, onError, onPartialResult, onResult`

  ### Methods inherited from class Object

  `clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

  ### Methods inherited from interface RecognitionCallback

  `onEnd, onError, onPartialResult, onResult`

- ## Constructor Details

  - ### Adapter

    public Adapter()

- ## Method Details

  - ### onPartialResult

    public void onPartialResult(TranscriptionResult result)
    Forwards partial timed results to the string-only partial callback.
    Specified by:
      `onPartialResult` in interface `TimedRecognitionCallback`
    Parameters:
      `result` - partial timed recognition result

  - ### onResult

    public void onResult(TranscriptionResult result, float confidence, String[] alternatives)
    Forwards final timed results to the string-only result callback.
    Specified by:
      `onResult` in interface `TimedRecognitionCallback`
    Parameters:
      `result` - final timed recognition result
      `confidence` - confidence score from `0.0` to `1.0`, when available
      `alternatives` - provider-specific alternative transcripts