use of com.sun.voip.CallParticipant in project Openfire by igniterealtime.
the class CallHandler method setMuteWhisperGroup.
/**
* Mute or unmute member in a whisperGroup
*/
public static void setMuteWhisperGroup(String callId, boolean isMuted) {
if (callId == null) {
return;
}
synchronized (activeCalls) {
for (int i = 0; i < activeCalls.size(); i++) {
CallHandler call = (CallHandler) activeCalls.elementAt(i);
CallParticipant cp = call.getCallParticipant();
if (match(cp, callId)) {
if (Logger.logLevel >= Logger.LOG_DETAIL) {
String s = "";
if (isMuted == false) {
s = "un";
}
Logger.println(cp.getCallId() + ": " + s + "muted");
}
MemberReceiver memberReceiver = call.getMemberReceiver();
if (memberReceiver != null) {
memberReceiver.setMuteWhisperGroup(isMuted);
}
}
}
}
}
use of com.sun.voip.CallParticipant in project Openfire by igniterealtime.
the class CallHandler method setCnThresh.
/*
* Set cnThresh for the speech detector for a conference member.
*/
public static void setCnThresh(String callId, int cnThresh) {
synchronized (activeCalls) {
for (int i = 0; i < activeCalls.size(); i++) {
CallHandler call = (CallHandler) activeCalls.elementAt(i);
CallParticipant cp = call.getCallParticipant();
if (match(cp, callId)) {
MemberReceiver memberReceiver = call.getMemberReceiver();
if (memberReceiver != null) {
memberReceiver.setCnThresh(cnThresh);
}
}
}
}
}
use of com.sun.voip.CallParticipant in project Openfire by igniterealtime.
the class CallHandler method setConferenceMuted.
/**
* Mute or unmute a conference from a particular call.
*/
public static void setConferenceMuted(String callId, boolean isMuted) {
if (callId == null) {
return;
}
synchronized (activeCalls) {
for (int i = 0; i < activeCalls.size(); i++) {
CallHandler call = (CallHandler) activeCalls.elementAt(i);
CallParticipant cp = call.getCallParticipant();
if (match(cp, callId)) {
if (Logger.logLevel >= Logger.LOG_DETAIL) {
String s = "";
if (isMuted == false) {
s = "un";
}
Logger.println(cp.getCallId() + ": conference " + s + "muted");
}
ConferenceMember member = call.getMember();
if (member != null) {
member.setConferenceMuted(isMuted);
}
}
}
}
}
use of com.sun.voip.CallParticipant in project Openfire by igniterealtime.
the class CallHandler method setPowerThresholdLimit.
/*
* Set powerThresholdLimit for the speech detector for a member.
*/
public static void setPowerThresholdLimit(String callId, double powerThresholdLimit) {
synchronized (activeCalls) {
for (int i = 0; i < activeCalls.size(); i++) {
CallHandler call = (CallHandler) activeCalls.elementAt(i);
CallParticipant cp = call.getCallParticipant();
if (match(cp, callId)) {
MemberReceiver memberReceiver = call.getMemberReceiver();
if (memberReceiver != null) {
memberReceiver.setPowerThresholdLimit(powerThresholdLimit);
}
}
}
}
}
use of com.sun.voip.CallParticipant in project Openfire by igniterealtime.
the class CallHandler method setDropPackets.
/*
* force packets to be dropped for debugging.
*/
public static void setDropPackets(String callId, int dropPackets) {
if (callId == null) {
return;
}
synchronized (activeCalls) {
for (int i = 0; i < activeCalls.size(); i++) {
CallHandler call = (CallHandler) activeCalls.elementAt(i);
CallParticipant cp = call.getCallParticipant();
if (match(cp, callId)) {
MemberReceiver memberReceiver = call.getMemberReceiver();
if (memberReceiver != null) {
memberReceiver.setDropPackets(dropPackets);
}
}
}
}
}
Aggregations