Class OmniRealtimeCallback

java.lang.Object
com.alibaba.dashscope.legacy_2x.audio.omni.OmniRealtimeCallback

@Deprecated public abstract class OmniRealtimeCallback extends Object
Deprecated.
Author:
lengjiayi
  • Constructor Summary

    Constructors
    Constructor
    Description
    Deprecated.
     
  • Method Summary

    Modifier and Type
    Method
    Description
    abstract void
    onClose(int code, String reason)
    Deprecated.
    Will be called when the connection is closed.
    void
    onError(Throwable throwable)
    Deprecated.
    Will be called when the websocket connection fails, e.g. network disconnected, connect timeout, or other io exceptions.
    abstract void
    onEvent(com.google.gson.JsonObject message)
    Deprecated.
    Will be called as soon as the server replies.
    void
    Deprecated.
    Will be called as soon as the connection is established, only for http stream request.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • OmniRealtimeCallback

      public OmniRealtimeCallback()
      Deprecated.
  • Method Details

    • onOpen

      public void onOpen()
      Deprecated.
      Will be called as soon as the connection is established, only for http stream request.
    • onEvent

      public abstract void onEvent(com.google.gson.JsonObject message)
      Deprecated.
      Will be called as soon as the server replies.
      Parameters:
      message - The message body in json.
    • onClose

      public abstract void onClose(int code, String reason)
      Deprecated.
      Will be called when the connection is closed.
    • onError

      public void onError(Throwable throwable)
      Deprecated.
      Will be called when the websocket connection fails, e.g. network disconnected, connect timeout, or other io exceptions. Default implementation does nothing, override it to be notified of such errors.
      Parameters:
      throwable - the exception that caused the failure.