aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordamencho <damencho@jitsi.org>2015-08-14 17:14:11 -0500
committerdamencho <damencho@jitsi.org>2015-08-14 17:14:11 -0500
commit5d1032133bbbae0be75631f56dd17a56bb8d062d (patch)
treea1eb1756627a18028d0d7c943f37669bc780701e
parent20aba12e18a0d2dd86633a1ae34f9152c6e3340d (diff)
downloadjitsi-5d1032133bbbae0be75631f56dd17a56bb8d062d.zip
jitsi-5d1032133bbbae0be75631f56dd17a56bb8d062d.tar.gz
jitsi-5d1032133bbbae0be75631f56dd17a56bb8d062d.tar.bz2
Adds optional name attribute to the conference element in colibri.
-rw-r--r--src/net/java/sip/communicator/impl/protocol/jabber/extensions/colibri/ColibriAnalyser.java1
-rw-r--r--src/net/java/sip/communicator/impl/protocol/jabber/extensions/colibri/ColibriBuilder.java1
-rw-r--r--src/net/java/sip/communicator/impl/protocol/jabber/extensions/colibri/ColibriConferenceIQ.java62
-rw-r--r--src/net/java/sip/communicator/impl/protocol/jabber/extensions/colibri/ColibriIQProvider.java6
4 files changed, 69 insertions, 1 deletions
diff --git a/src/net/java/sip/communicator/impl/protocol/jabber/extensions/colibri/ColibriAnalyser.java b/src/net/java/sip/communicator/impl/protocol/jabber/extensions/colibri/ColibriAnalyser.java
index 4e3f20a..cdd4d4f 100644
--- a/src/net/java/sip/communicator/impl/protocol/jabber/extensions/colibri/ColibriAnalyser.java
+++ b/src/net/java/sip/communicator/impl/protocol/jabber/extensions/colibri/ColibriAnalyser.java
@@ -125,6 +125,7 @@ public class ColibriAnalyser
conferenceResult.setFrom(conferenceResponse.getFrom());
conferenceResult.setID(conferenceResponse.getID());
+ conferenceResult.setName(conferenceResponse.getName());
// FIXME: we support single bundle for all channels
String bundleId = null;
diff --git a/src/net/java/sip/communicator/impl/protocol/jabber/extensions/colibri/ColibriBuilder.java b/src/net/java/sip/communicator/impl/protocol/jabber/extensions/colibri/ColibriBuilder.java
index be588d3..547ebe8 100644
--- a/src/net/java/sip/communicator/impl/protocol/jabber/extensions/colibri/ColibriBuilder.java
+++ b/src/net/java/sip/communicator/impl/protocol/jabber/extensions/colibri/ColibriBuilder.java
@@ -146,6 +146,7 @@ public class ColibriBuilder
// that new conference will be allocated
request = new ColibriConferenceIQ();
request.setID(conferenceState.getID());
+ request.setName(conferenceState.getName());
}
/**
diff --git a/src/net/java/sip/communicator/impl/protocol/jabber/extensions/colibri/ColibriConferenceIQ.java b/src/net/java/sip/communicator/impl/protocol/jabber/extensions/colibri/ColibriConferenceIQ.java
index 63c71c7..1b403b2 100644
--- a/src/net/java/sip/communicator/impl/protocol/jabber/extensions/colibri/ColibriConferenceIQ.java
+++ b/src/net/java/sip/communicator/impl/protocol/jabber/extensions/colibri/ColibriConferenceIQ.java
@@ -52,6 +52,13 @@ public class ColibriConferenceIQ
public static final String ID_ATTR_NAME = "id";
/**
+ * The XML name of the <tt>name</tt> attribute of the Jitsi Videobridge
+ * <tt>conference</tt> IQ which represents the value of the <tt>name</tt>
+ * property of <tt>ColibriConferenceIQ</tt> if available.
+ */
+ public static final String NAME_ATTR_NAME = "name";
+
+ /**
* The XML COnferencing with LIghtweight BRIdging namespace of the Jitsi
* Videobridge <tt>conference</tt> IQ.
*/
@@ -107,6 +114,11 @@ public class ColibriConferenceIQ
private boolean gracefulShutdown;
/**
+ * World readable name for the conference.
+ */
+ private String name;
+
+ /**
* Returns an error response for given <tt>IQ</tt> that is returned by
* the videobridge after it has entered graceful shutdown mode and new
* conferences can no longer be created.
@@ -252,6 +264,10 @@ public class ColibriConferenceIQ
xml.append(' ').append(ID_ATTR_NAME).append("='").append(id)
.append('\'');
+ if (name != null)
+ xml.append(' ').append(NAME_ATTR_NAME).append("='").append(name)
+ .append('\'');
+
List<Content> contents = getContents();
List<ChannelBundle> channelBundles = getChannelBundles();
@@ -437,6 +453,24 @@ public class ColibriConferenceIQ
}
/**
+ * The world readable name of the conference.
+ * @return name of the conference.
+ */
+ public String getName()
+ {
+ return name;
+ }
+
+ /**
+ * Sets name.
+ * @param name the name to set.
+ */
+ public void setName(String name)
+ {
+ this.name = name;
+ }
+
+ /**
* Represents a <tt>channel</tt> included into a <tt>content</tt> of a Jitsi
* Videobridge <tt>conference</tt> IQ.
*/
@@ -2174,27 +2208,53 @@ public class ColibriConferenceIQ
*/
public static final String TOKEN_ATTR_NAME = "token";
+ /**
+ * The target directory.
+ */
private String directory;
+ /**
+ * State of the recording..
+ */
private State state;
+ /**
+ * Access token.
+ */
private String token;
+ /**
+ * Construct new recording element.
+ * @param state the state as string
+ */
public Recording(String state)
{
this.state = State.parseString(state);
}
+ /**
+ * Construct new recording element.
+ * @param state
+ */
public Recording(State state)
{
this.state = state;
}
+ /**
+ * Construct new recording element.
+ * @param state the state as string
+ * @param token the token to authenticate
+ */
public Recording(String state, String token)
{
this(State.parseString(state), token);
}
-
+ /**
+ * Construct new recording element.
+ * @param state the state
+ * @param token the token to authenticate
+ */
public Recording(State state, String token)
{
this(state);
diff --git a/src/net/java/sip/communicator/impl/protocol/jabber/extensions/colibri/ColibriIQProvider.java b/src/net/java/sip/communicator/impl/protocol/jabber/extensions/colibri/ColibriIQProvider.java
index 42e136a..39e299f 100644
--- a/src/net/java/sip/communicator/impl/protocol/jabber/extensions/colibri/ColibriIQProvider.java
+++ b/src/net/java/sip/communicator/impl/protocol/jabber/extensions/colibri/ColibriIQProvider.java
@@ -249,6 +249,12 @@ public class ColibriIQProvider
if ((conferenceID != null) && (conferenceID.length() != 0))
conference.setID(conferenceID);
+ String conferenceName = parser
+ .getAttributeValue("", ColibriConferenceIQ.NAME_ATTR_NAME);
+
+ if ((conferenceName != null) && (conferenceName.length() != 0))
+ conference.setName(conferenceName);
+
boolean done = false;
ColibriConferenceIQ.Channel channel = null;
ColibriConferenceIQ.RTCPTerminationStrategy rtcpTerminationStrategy