mirror of https://github.com/OpenVidu/openvidu.git
openvidu-server: Network quality
- Added method to send notification with network quality - Added double parser methodpull/546/head
parent
70831114fe
commit
80a052fcea
|
@ -772,6 +772,20 @@ public class OpenviduConfig {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
protected Double asNonNegativeDouble(String property) {
|
||||||
|
try {
|
||||||
|
Double doubleValue = Double.parseDouble(getValue(property));
|
||||||
|
|
||||||
|
if (doubleValue < 0) {
|
||||||
|
addError(property, "Is not a non negative double");
|
||||||
|
}
|
||||||
|
return doubleValue;
|
||||||
|
} catch (NumberFormatException e) {
|
||||||
|
addError(property, "Is not a non negative doubleValue");
|
||||||
|
return 0.0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* This method checks all types of Internet addresses (IPv4, IPv6 and Domains)
|
* This method checks all types of Internet addresses (IPv4, IPv6 and Domains)
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -311,6 +311,10 @@ public class SessionEventsHandler {
|
||||||
rpcNotificationService.sendResponse(participant.getParticipantPrivateId(), transactionId, new JsonObject());
|
rpcNotificationService.sendResponse(participant.getParticipantPrivateId(), transactionId, new JsonObject());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void onNetworkQualityChanged(Participant participant, JsonObject params ) {
|
||||||
|
rpcNotificationService.sendNotification(participant.getParticipantPrivateId(), ProtocolElements.NETWORKQUALITYCHANGED_METHOD, params);
|
||||||
|
}
|
||||||
|
|
||||||
public void onSendMessage(Participant participant, JsonObject message, Set<Participant> participants,
|
public void onSendMessage(Participant participant, JsonObject message, Set<Participant> participants,
|
||||||
Integer transactionId, OpenViduException error) {
|
Integer transactionId, OpenViduException error) {
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue