Package com.opentok.android
Class Connection
- java.lang.Object
-
- com.opentok.android.Connection
-
public final class Connection extends java.lang.Object
Represents a connection between a client and an OpenTok session. TheSession.getConnection()
method returns a Connection object that represents the local user's connection. TheStream.getConnection()
method returns a Connection object that represents the stream publisher's connection.To initialize a session, call the Session() constructor, which returns the Session object. Then call the connect() method of the Session object to connect to the session. When the connection to the session is made, the
Session.SessionListener.onConnected(Session session)
method is called.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object object)
protected void
finalize()
java.lang.String
getConnectionId()
java.util.Date
getCreationTime()
java.lang.String
getData()
int
hashCode()
-
-
-
Method Detail
-
getConnectionId
public java.lang.String getConnectionId()
- Returns:
- The unique ID for this connection.
-
getData
public java.lang.String getData()
- Returns:
- A string containing metadata describing the connection. You can add this connection data when you create a token.
-
getCreationTime
public java.util.Date getCreationTime()
- Returns:
- Returns the time at which the connection was created on the OpenTok server.
-
finalize
protected void finalize() throws java.lang.Throwable
- Overrides:
finalize
in classjava.lang.Object
- Throws:
java.lang.Throwable
-
equals
public boolean equals(@Nullable java.lang.Object object)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
-