Class KurentoClient

java.lang.Object
org.kurento.client.KurentoClient

public class KurentoClient extends Object
Factory to create MediaPipeline in the media server.
Since:
2.0.0
Author:
Luis López (llopez@gsyc.es), Ivan Gracia (igracia@gsyc.es), Micael Gallego (micael.gallego@gmail.com)
  • Field Details

    • manager

      protected org.kurento.client.internal.client.RomManager manager
  • Constructor Details

    • KurentoClient

      protected KurentoClient(org.kurento.jsonrpc.client.JsonRpcClient client)
    • KurentoClient

      protected KurentoClient(org.kurento.jsonrpc.client.JsonRpcClient client, boolean overrideClientTimeouts)
  • Method Details

    • getKmsUrl

      public static String getKmsUrl(String id, Properties properties)
    • create

      public static KurentoClient create()
    • create

      public static KurentoClient create(Properties properties)
    • create

      public static KurentoClient create(String websocketUrl)
    • create

      public static KurentoClient create(String websocketUrl, Properties properties)
    • configureJsonRpcClient

      protected static void configureJsonRpcClient(org.kurento.jsonrpc.client.AbstractJsonRpcClientWebSocket client)
    • create

      public static KurentoClient create(String websocketUrl, KurentoConnectionListener listener)
    • create

      public static KurentoClient create(Properties properties, KurentoConnectionListener listener)
    • create

      public static KurentoClient create(String websocketUrl, KurentoConnectionListener listener, Properties properties)
    • create

      protected static KurentoClient create(String kmsWsUri, Properties properties, Handler connectedHandler, Handler connectionFailedHandler, Handler reconnectingHandler, Handler disconnectedHandler, ReconnectedHandler reconnectedHandler, Long tryReconnectingMaxTime, Long connectionTimeout)
    • createMediaPipeline

      public MediaPipeline createMediaPipeline()
      Creates a new MediaPipeline in the media server.
      Returns:
      The media pipeline
    • createMediaPipeline

      public void createMediaPipeline(Continuation<MediaPipeline> cont) throws org.kurento.commons.exception.KurentoException
      Creates a new MediaPipeline in the media server.
      Parameters:
      cont - An asynchronous callback handler. If the element was successfully created, the onSuccess method from the handler will receive a MediaPipeline stub from the media server.
      Throws:
      org.kurento.commons.exception.KurentoException
    • createMediaPipeline

      public MediaPipeline createMediaPipeline(Transaction tx)
    • createMediaPipeline

      public MediaPipeline createMediaPipeline(Properties properties)
      Creates a new MediaPipeline in the media server.
      Returns:
      The media pipeline
    • createMediaPipeline

      public void createMediaPipeline(Properties properties, Continuation<MediaPipeline> cont) throws org.kurento.commons.exception.KurentoException
      Creates a new MediaPipeline in the media server.
      Parameters:
      cont - An asynchronous callback handler. If the element was successfully created, the onSuccess method from the handler will receive a MediaPipeline stub from the media server.
      Throws:
      org.kurento.commons.exception.KurentoException
    • createMediaPipeline

      public MediaPipeline createMediaPipeline(Transaction tx, Properties properties)
    • destroy

      @PreDestroy public void destroy()
    • isClosed

      public boolean isClosed()
    • isDestroyed

      public boolean isDestroyed()
    • createFromJsonRpcClient

      public static KurentoClient createFromJsonRpcClient(org.kurento.jsonrpc.client.JsonRpcClient jsonRpcClient)
    • createFromJsonRpcClientHonoringClientTimeouts

      public static KurentoClient createFromJsonRpcClientHonoringClientTimeouts(org.kurento.jsonrpc.client.JsonRpcClient jsonRpcClient)
    • beginTransaction

      public Transaction beginTransaction()
    • getServerManager

      public ServerManager getServerManager()
    • getById

      public <T extends KurentoObject> T getById(String id, Class<T> clazz)
    • getSessionId

      public String getSessionId()
    • setLabel

      public void setLabel(String label)
    • getLabel

      public String getLabel()
    • sendJsonRpcRequest

      public org.kurento.jsonrpc.message.Response<com.google.gson.JsonElement> sendJsonRpcRequest(org.kurento.jsonrpc.message.Request<com.google.gson.JsonObject> request) throws IOException
      Throws:
      IOException