mirror of
https://github.com/vanitasvitae/Smack.git
synced 2024-11-23 20:42:06 +01:00
Merge master
This commit is contained in:
commit
62587daa35
1 changed files with 7 additions and 0 deletions
|
@ -489,6 +489,13 @@ public class JingleSession {
|
||||||
return contents.get(name);
|
return contents.get(name);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get the only jingle content if one exists, or <code>null</code>. This method will throw an
|
||||||
|
* {@link IllegalStateException} if there is more than one jingle content.
|
||||||
|
*
|
||||||
|
* @return a JingleContent instance or <code>null</code>.
|
||||||
|
* @throws IllegalStateException if there is more than one jingle content.
|
||||||
|
*/
|
||||||
public JingleContent getSoleContentOrThrow() {
|
public JingleContent getSoleContentOrThrow() {
|
||||||
if (contents.isEmpty()) {
|
if (contents.isEmpty()) {
|
||||||
return null;
|
return null;
|
||||||
|
|
Loading…
Reference in a new issue