Interface Conference


public interface Conference
A conference is the object that allow to make calls when there are 2 or more
participants.

To create (or find) a Conference, you first need a ConferenceParams
object. Core.createConferenceWithParams(org.linphone.core.ConferenceParams) allows you to create a
conference. A conference is uniquely identified by a conference address,
meaning you can have more than one conference between two accounts. As of now,
each Core can host only 1 conference but it can be part of many
conferences as a remote participant. To find a conference among those a core is
part of, you can call Core.searchConference(org.linphone.core.ConferenceParams, org.linphone.core.Address, org.linphone.core.Address, org.linphone.core.Address[]).
  • Method Details

    • getActiveSpeakerParticipantDevice

      @Nullable ParticipantDevice getActiveSpeakerParticipantDevice()
      Get the currently active speaker participant device.

      Returns:
      the ParticipantDevice currently displayed as active speaker.
    • getCall

      @Nullable Call getCall()
      Gets the call that is controlling a conference.

      Returns:
      the Call controlling the conference or null if none or local
      conference
    • getConferenceAddress

      @NonNull Address getConferenceAddress()
      Get the conference address of the conference.

      Returns:
      The conference address of the conference.
    • setConferenceAddress

      void setConferenceAddress(@NonNull Address address)
      Set the conference address.

      Parameters:
      address - the conference address to set.
      warning: This is only allowed for a remote conference if it is in state
      CreationPending or Instantiated
    • getCore

      @NonNull Core getCore()
      Returns core for a Conference.

      Returns:
      back pointer to Core object. Returns back pointer to Core
      object.
    • getCurrentParams

      @NonNull ConferenceParams getCurrentParams()
      Get current parameters of the conference.

      Returns:
      a ConferenceParams .
    • getDuration

      @Nullable int getDuration()
      Get the conference duration.

      Returns:
      conference duration.
    • getId

      @Deprecated @NonNull String getId()
      Deprecated.
      10/07/2020 Use getConferenceAddress() instead.
      Get the conference id as string.

      Returns:
      the conference id
    • setId

      @Deprecated void setId(@NonNull String conferenceId)
      Deprecated.
      Set the conference id as string.

      Parameters:
      conferenceId - the conference id to set.
    • getInputAudioDevice

      @Nullable AudioDevice getInputAudioDevice()
      Gets the current input device for this conference.

      Returns:
      the AudioDevice used by this conference as input or null if
      there is currently no soundcard configured (depending on the state of the
      conference)
    • setInputAudioDevice

      void setInputAudioDevice(@Nullable AudioDevice audioDevice)
      Sets the given AudioDevice as input for this conference only.

      Parameters:
      audioDevice - The AudioDevice. null does nothing.
    • getInputVolume

      float getInputVolume()
      Retrieves the volume of a specific participant.

      Returns:
      The volume of the participant expressed in dbm0.
    • isIn

      boolean isIn()
      For a local conference, it returns whether the local participant is enabled For
      a remote conference, it return whether the remote participant has left the
      conference without bein removed from it.

      Returns:
      true if the local participant is in a conference, false otherwise.
    • isRecording

      boolean isRecording()
      Gets whether the conference is currently being recorded.

      Returns:
      true if conference is being recorded, false otherwise.
    • getMe

      @NonNull Participant getMe()
      For a local audio video conference, this function returns the participant
      hosting the conference For a remote audio video conference, this function
      returns the local participant of the conference.

      Returns:
      a Participant .
    • getMicrophoneMuted

      boolean getMicrophoneMuted()
      Retrieves the volume of a specific participant.

      Returns:
      The volume of the participant expressed in dbm0.
    • setMicrophoneMuted

      void setMicrophoneMuted(boolean muted)
      Get microphone muted state.

      Note that the microphone may be disabled globally if false was given to Core#enableMic
      .
    • getOutputAudioDevice

      @Nullable AudioDevice getOutputAudioDevice()
      Gets the current output device for this conference.

      Returns:
      the AudioDevice used by this conference as output or null if
      there is currently no soundcard configured (depending on the state of the
      conference)
    • setOutputAudioDevice

      void setOutputAudioDevice(@Nullable AudioDevice audioDevice)
      Sets the given AudioDevice as output for this conference only.

      Parameters:
      audioDevice - The AudioDevice. null does nothing.
    • getParticipantCount

      int getParticipantCount()
      Get number of participants without me.

      Returns:
      the number of participants excluding me in a Conference
    • getParticipantDeviceList

      @NonNull ParticipantDevice[] getParticipantDeviceList()
      Get list of all participant devices of a conference including me if it is in.

      Returns:
      The list of participant devices of the conference.
    • getParticipantList

      @NonNull Participant[] getParticipantList()
      Get list of all participants of a conference.

      warning: The returned list does not include me.
      Returns:
      The list of participants of the conference.
    • getParticipants

      @Deprecated @NonNull Address[] getParticipants()
      Deprecated.
      10/07/2020 Use getParticipantList() instead.
      Get URIs of all participants of one conference The returned bctbx_list_t
      contains URIs of all participants.

      That list must be freed after use and each URI must be unref with
      linphone_address_unref warning: The returned list does not include me.
      Returns:
      The list of the participants' address active in the conference.
    • getStartTime

      @Nullable long getStartTime()
      Get the conference start time.

      Returns:
      conference start time.
    • getState

      Conference.State getState()
      Get the current state of the conference.

      Returns:
      the Conference.State of the conference.
    • getSubject

      @Nullable String getSubject()
      Get the conference subject.

      Returns:
      conference subject.
    • setSubject

      void setSubject(@Nullable String subject)
      Set the conference subject.

      Parameters:
      subject - conference subject
    • getUsername

      @Nullable String getUsername()
      Get the conference username.

      Returns:
      conference subject.
    • setUsername

      void setUsername(@Nullable String username)
      Set the conference username.

      Parameters:
      username - conference subject
    • addParticipant

      int addParticipant(@NonNull Call call)
      Join an existing call to the conference.

      If the conference is in the state LinphoneConferenceStateCreationPending, then
      the conference will start on the input and output audio devices used for the
      currently active call, if any
      Parameters:
      call - a Call that has to be added to the conference.
      warning: This function guarantees that the local endpoint is added to the
      conference only if one of calls added is in state StreamsRunning. It is highly
      recommended to call linphone_confererence_enter() to guarantee that the local
      endpoint is added to the conference.
    • addParticipant

      int addParticipant(@NonNull Address uri)
      Join a participant to the conference.

      Parameters:
      uri - a Address that has to be added to the conference.
      warning: This function guarantees that the local endpoint is added to the
      conference only if there is a call state StreamsRunning towards one of the
      addresses. It is highly recommended to call linphone_confererence_enter() to
      guarantee that the local endpoint is added to the conference.
    • addParticipants

      int addParticipants(@NonNull Call[] calls)
      Add participants to the conference, by supplying a list of Call.

      If the conference is in the state LinphoneConferenceStateCreationPending, then
      the conference will start on the input and output audio devices used for the
      currently active call, if any
      Parameters:
      calls - A list of calls to add to the conference.
    • addParticipants

      int addParticipants(@NonNull Address[] addresses)
      Add participants to the conference, by supplying a list of Address.

      Parameters:
      addresses - A list of calls to add to the conference.
    • enter

      int enter()
      For a local conference, the local participant joins the conference For a remote
      conference, the participant rejoins the conference after leaving it earlier on.

      Returns:
      0 if succeeded. Negative number if failed
    • findParticipant

      @Nullable Participant findParticipant(@NonNull Address uri)
      Find a participant from a conference.

      Parameters:
      uri - SIP URI of the participant to search.
      Returns:
      a pointer to the participant found or nullptr.
    • getParticipantDeviceVolume

      int getParticipantDeviceVolume(@NonNull ParticipantDevice device)
      Retrieves the volume of a specific participant.

      Parameters:
      device - The Participant
      Returns:
      The volume of the participant expressed in dbm0.
    • inviteParticipants

      int inviteParticipants(@NonNull Address[] addresses, @Nullable CallParams params)
      Invite participants to the conference, by supplying a list of Address
      If the conference is in the state LinphoneConferenceStateCreationPending, then
      the conference will start on the input and output audio devices used for the
      currently active call, if any.

      Parameters:
      addresses - A list of SIP addresses to invite.
      params - CallParams to use for inviting the participants.
    • isMe

      boolean isMe(@NonNull Address uri)
      For a local audio video conference, this function compares the address provided
      as argument with that of participant hosting the conference For a remote audio
      video conference, this function compares the address provided as argument with
      that of the local participant of the conference.

      Parameters:
      uri - A Address object
      Returns:
      true if the participant is me, false otherwise.
    • leave

      int leave()
      For a local conference, the local participant leaves the conference For a
      remote conference, the participant leaves the conference after joining it
      earlier on.

      Returns:
      0 if succeeded. Negative number if failed
    • removeParticipant

      @Deprecated int removeParticipant(@NonNull Address uri)
      Deprecated.

      Parameters:
      uri - URI of the participant to remove
      warning: The passed participant uri must be one of those returned by getParticipants()
      Returns:
      0 if succeeded, -1 if failed
    • removeParticipant

      int removeParticipant(@NonNull Participant participant)

      Parameters:
      participant - participant to remove
      warning: The passed participant must be one of those returned by getParticipantList()
      warning: This method may destroy the conference if the only remaining
      participant had an existing call to the local participant before the conference
      was created
      Returns:
      0 if succeeded, -1 if failed
    • removeParticipant

      @Deprecated int removeParticipant(@NonNull Call call)
      Deprecated.

      Parameters:
      call - call to remove
      Returns:
      0 if succeeded, -1 if failed
    • setLocalParticipantStreamCapability

      void setLocalParticipantStreamCapability(MediaDirection direction, StreamType type)
      Set stream capability on me device of a local conference.

      Parameters:
      direction - the direction of stream of type stream_type
    • setParticipantAdminStatus

      void setParticipantAdminStatus(@NonNull Participant participant, boolean isAdmin)
      Change the admin status of a participant of a conference (you need to be an
      admin yourself to do this).

      Parameters:
      participant - The Participant for which to change the admin status
      isAdmin - A boolean value telling whether the participant should now be an
      admin or not
    • startRecording

      int startRecording(@NonNull String path)
      Starts recording the conference.

      Parameters:
      path - Where to record the conference
      Returns:
      0 if succeeded. Negative number in case of failure.
    • stopRecording

      int stopRecording()
      Stops the conference recording.

      Returns:
      0 if succeeded. Negative number in case of failure.
    • terminate

      int terminate()
      Terminates conference.

      Returns:
      0 if the termination is successful, -1 otherwise.
    • updateParams

      int updateParams(@NonNull ConferenceParams params)
      Update parameters of the conference.

      This is typically used enable or disable the video stream in the conference.
      Parameters:
      params - the new parameters to apply.
    • addListener

      void addListener(ConferenceListener listener)
    • removeListener

      void removeListener(ConferenceListener listener)
    • setUserData

      void setUserData(Object data)
      Sets the object to store in this object user's data
      Parameters:
      data - the object to store
    • getUserData

      Object getUserData()
      Gets the object stored in this object user's data
      Returns:
      the object store if any, null otherwise
    • getNativePointer

      long getNativePointer()
      Gets the native pointer used by this class to make native method calls.
      Returns:
      the nativer pointer, as long
    • toString

      String toString()
      Overrides:
      toString in class Object