Modified: 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/documents/LoadLibraryPresentationToObject.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/documents/LoadLibraryPresentationToObject.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/documents/LoadLibraryPresentationToObject.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/documents/LoadLibraryPresentationToObject.java
 Wed Mar  1 06:11:13 2017
@@ -31,9 +31,9 @@ import org.red5.logging.Red5LoggerFactor
 import org.slf4j.Logger;
 
 public class LoadLibraryPresentationToObject {
-       
+
        private static final Logger log = 
Red5LoggerFactory.getLogger(LoadLibraryPresentationToObject.class, 
OpenmeetingsVariables.webAppRootKey);
-       
+
        private static LoadLibraryPresentationToObject instance;
 
        private LoadLibraryPresentationToObject() {}
@@ -43,25 +43,25 @@ public class LoadLibraryPresentationToOb
                        instance = new LoadLibraryPresentationToObject();
                }
                return instance;
-       }       
-       
+       }
+
        public PresentationObject parseLibraryFileToObject(String filePath){
                try {
                        PresentationObject lMap = new PresentationObject();
-                       
-               SAXReader reader = new SAXReader();
-               Document document = reader.read(filePath);
-               
-               Element root = document.getRootElement();
-               Integer k = 0;
-               
-               for (@SuppressWarnings("unchecked")
+
+               SAXReader reader = new SAXReader();
+               Document document = reader.read(filePath);
+
+               Element root = document.getRootElement();
+               Integer k = 0;
+
+               for (@SuppressWarnings("unchecked")
                        Iterator<Element> i = root.elementIterator(); 
i.hasNext(); ) {
-                   Element item = i.next();
-                   log.error(item.getName());
-                   
-                   String nodeVal = item.getName();
-                   
+                       Element item = i.next();
+                       log.error(item.getName());
+
+                       String nodeVal = item.getName();
+
                                if (nodeVal.equals("originalDocument")){
                                        
lMap.setOriginalDocument(this.createListObjectLibraryByFileDocument(item));
                                } else if (nodeVal.equals("pdfDocument")){
@@ -71,21 +71,21 @@ public class LoadLibraryPresentationToOb
                                } else if (nodeVal.equals("thumbs")) {
                                        
lMap.setThumbs(this.createListObjectLibraryByFileDocumentThumbs(item));
                                }
-                   
-                   k++;
 
-               }
-                       
+                       k++;
+
+               }
+
                        return lMap;
                } catch (Exception err) {
                        log.error("parseLibraryFileToObject",err);
                        return null;
                }
        }
-       
+
        public FileExplorerItemDTO 
createListObjectLibraryByFileDocument(Element fileElement){
                try {
-                       
+
                        
log.info("createListObjectLibraryByFileDocument"+fileElement);
                        FileExplorerItemDTO fileObject = new 
FileExplorerItemDTO();
                        fileObject.setName(fileElement.getText());
@@ -96,13 +96,13 @@ public class LoadLibraryPresentationToOb
                        log.error("createListObjectLibraryByFileDocument",err);
                }
                return null;
-       }               
-       
+       }
+
        public LinkedList<FileExplorerItemDTO> 
createListObjectLibraryByFileDocumentThumbs(Element fileElement){
                try {
 
-                       LinkedList<FileExplorerItemDTO> thumbMap = new 
LinkedList<FileExplorerItemDTO>();
-                       
+                       LinkedList<FileExplorerItemDTO> thumbMap = new 
LinkedList<>();
+
                        for (@SuppressWarnings("unchecked")
                        Iterator<Element> i = fileElement.elementIterator(); 
i.hasNext(); ) {
                                Element thumbElement = i.next();
@@ -114,13 +114,13 @@ public class LoadLibraryPresentationToOb
                                //FIXME TODO 
singleThumb.setSize(thumbElement.attribute("size").getText());
                                thumbMap.add(singleThumb);
                        }
-                       
+
                        return thumbMap;
-                       
+
                } catch (Exception err) {
                        
log.error("createListObjectLibraryByFileDocumentThumbs",err);
                }
                return null;
-       }       
-       
+       }
+
 }

Modified: 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/ConferenceLibrary.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/ConferenceLibrary.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/ConferenceLibrary.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/ConferenceLibrary.java
 Wed Mar  1 06:11:13 2017
@@ -177,7 +177,7 @@ public class ConferenceLibrary implement
                        whiteboardManagement.addWhiteBoardObjectById(roomId, 
whiteboardObj, wbId);
                }
 
-               Map<String, Object> sendObject = new HashMap<String, Object>();
+               Map<String, Object> sendObject = new HashMap<>();
                sendObject.put("id", wbId);
                sendObject.put("roomitems", roomItems);
 

Modified: 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/MobileService.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/MobileService.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/MobileService.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/MobileService.java
 Wed Mar  1 06:11:13 2017
@@ -27,7 +27,6 @@ import static org.apache.openmeetings.ut
 import static org.apache.openmeetings.util.OpenmeetingsVariables.webAppRootKey;
 import static org.apache.openmeetings.util.Version.getVersion;
 
-import java.io.Serializable;
 import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.Date;
@@ -382,7 +381,7 @@ public class MobileService {
        }
 
        public void sendChatMessage(Client c, ChatMessage m, FastDateFormat 
fmt) {
-               HashMap<String, Object> hsm = new HashMap<String, Object>();
+               Map<String, Object> hsm = new HashMap<>();
                hsm.put("client", c);
                hsm.put("message", Arrays.asList("chat", encodeChatMessage(m, 
fmt)));
 

Modified: 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/RecordingService.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/RecordingService.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/RecordingService.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/RecordingService.java
 Wed Mar  1 06:11:13 2017
@@ -65,7 +65,7 @@ public class RecordingService implements
         * red5 stream object might be gone when the user closes the browser. 
But each listener has an asynchronous
         * component that needs to be closed no matter how the user leaves the 
application!
         */
-       private static final Map<Long, StreamListener> streamListeners = new 
ConcurrentHashMap<Long, StreamListener>();
+       private static final Map<Long, StreamListener> streamListeners = new 
ConcurrentHashMap<>();
 
        // Spring Beans
        @Autowired

Modified: 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/UserService.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/UserService.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/UserService.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/UserService.java
 Wed Mar  1 06:11:13 2017
@@ -23,6 +23,7 @@ import static org.apache.openmeetings.ut
 
 import java.util.HashMap;
 import java.util.List;
+import java.util.Map;
 
 import org.apache.openmeetings.IApplication;
 import org.apache.openmeetings.core.remote.red5.ScopeApplicationAdapter;
@@ -44,9 +45,9 @@ import org.springframework.beans.factory
 
 /**
  * Provides method to manipulate {@link User}
- * 
+ *
  * @author sebawagner
- * 
+ *
  */
 public class UserService implements IUserService {
        private static final Logger log = 
Red5LoggerFactory.getLogger(UserService.class, webAppRootKey);
@@ -66,7 +67,7 @@ public class UserService implements IUse
 
        /**
         * get user by id, admin only
-        * 
+        *
         * @param sid
         * @param userId
         * @return User with the id given
@@ -81,7 +82,7 @@ public class UserService implements IUse
 
        /**
         * refreshes the current SID
-        * 
+        *
         * @param SID
         * @return "ok" string in case of success, "error" string in case of 
the error
         */
@@ -97,7 +98,7 @@ public class UserService implements IUse
 
        /**
         * gets a whole user-list(admin-role only)
-        * 
+        *
         * @param sid
         * @param start
         * @param max
@@ -115,7 +116,7 @@ public class UserService implements IUse
        /**
         * kicks a user from the server, also from slaves if needed, this 
method is
         * only invoked by the connection administration UI
-        * 
+        *
         * @param sid
         * @param streamid
         * @param serverId
@@ -141,7 +142,7 @@ public class UserService implements IUse
                                        }
                                        IScope currentScope = 
scopeApplicationAdapter.getRoomScope(scopeName);
 
-                                       HashMap<Integer, String> messageObj = 
new HashMap<Integer, String>();
+                                       Map<Integer, String> messageObj = new 
HashMap<>();
                                        messageObj.put(0, "kick");
                                        
scopeApplicationAdapter.sendMessageById(messageObj, streamid, currentScope);
 
@@ -153,7 +154,7 @@ public class UserService implements IUse
                                        Client rcl = 
sessionManager.getClientByStreamId(
                                                        streamid, server);
                                        
slaveHTTPConnectionManager.kickSlaveUser(server, rcl.getPublicSID());
-                                       
+
                                        // true means only the REST call is 
performed, it is no
                                        // confirmation that the user is really 
kicked from the
                                        // slave
@@ -170,10 +171,10 @@ public class UserService implements IUse
         * Kick a user by its publicSID.<br/>
         * <br/>
         * <i>Note:</i>
-        * This method will not perform a call to the slave, cause this call 
can only be 
+        * This method will not perform a call to the slave, cause this call 
can only be
         * invoked from inside the conference room, that means all clients are 
on the
         * same server, no matter if clustered or not.
-        * 
+        *
         * @param sid
         * @param publicSID
         * @return - true in case user have sufficient permissions, null 
otherwise
@@ -194,7 +195,7 @@ public class UserService implements IUse
                                }
                                IScope currentScope = 
scopeApplicationAdapter.getRoomScope(scopeName);
 
-                               HashMap<Integer, String> messageObj = new 
HashMap<Integer, String>();
+                               Map<Integer, String> messageObj = new 
HashMap<>();
                                messageObj.put(0, "kick");
 
                                
scopeApplicationAdapter.sendMessageById(messageObj, rcl.getStreamid(), 
currentScope);

Modified: 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/WhiteBoardService.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/WhiteBoardService.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/WhiteBoardService.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/WhiteBoardService.java
 Wed Mar  1 06:11:13 2017
@@ -200,7 +200,7 @@ public class WhiteBoardService implement
                                                rcl.setCanDraw(canDraw);
                                                
sessionManager.updateClientByStreamId(rcl.getStreamid(), rcl, false, null);
 
-                                               HashMap<Integer, Object> 
newMessage = new HashMap<Integer, Object>();
+                                               Map<Integer, Object> newMessage 
= new HashMap<>();
                                                newMessage.put(0, 
"updateDrawStatus");
                                                newMessage.put(1, rcl);
                                                
scopeAdapter.sendMessageWithClientWithSyncObject(newMessage, true);
@@ -229,7 +229,7 @@ public class WhiteBoardService implement
                                                rcl.setCanShare(canShare);
                                                
sessionManager.updateClientByStreamId(rcl.getStreamid(), rcl, false, null);
 
-                                               HashMap<Integer, Object> 
newMessage = new HashMap<Integer, Object>();
+                                               Map<Integer, Object> newMessage 
= new HashMap<>();
                                                newMessage.put(0, 
"updateDrawStatus");
                                                newMessage.put(1, rcl);
                                                
scopeAdapter.sendMessageWithClientWithSyncObject(newMessage, true);
@@ -258,7 +258,7 @@ public class WhiteBoardService implement
                                                rcl.setCanRemote(canRemote);
                                                
sessionManager.updateClientByStreamId(rcl.getStreamid(), rcl, false, null);
 
-                                               HashMap<Integer, Object> 
newMessage = new HashMap<Integer, Object>();
+                                               Map<Integer, Object> newMessage 
= new HashMap<>();
                                                newMessage.put(0, 
"updateDrawStatus");
                                                newMessage.put(1, rcl);
                                                
scopeAdapter.sendMessageWithClientWithSyncObject(newMessage, true);
@@ -288,7 +288,7 @@ public class WhiteBoardService implement
                                                
rcl.setCanGiveAudio(canGiveAudio);
                                                
sessionManager.updateClientByStreamId(rcl.getStreamid(), rcl, false, null);
 
-                                               HashMap<Integer, Object> 
newMessage = new HashMap<Integer, Object>();
+                                               Map<Integer, Object> newMessage 
= new HashMap<>();
                                                newMessage.put(0, 
"updateGiveAudioStatus");
                                                newMessage.put(1, rcl);
                                                
scopeAdapter.sendMessageWithClientWithSyncObject(newMessage, true);

Modified: 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/red5/ScopeApplicationAdapter.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/red5/ScopeApplicationAdapter.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/red5/ScopeApplicationAdapter.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/remote/red5/ScopeApplicationAdapter.java
 Wed Mar  1 06:11:13 2017
@@ -215,6 +215,7 @@ public class ScopeApplicationAdapter ext
                                log.warn("Security code is invalid, client is 
rejected");
                                return rejectClient();
                        }
+                       rcm.setUsername(parent.getUsername());
                        rcm.setFirstname(parent.getFirstname());
                        rcm.setLastname(parent.getLastname());
                        rcm.setUserId(parent.getUserId());
@@ -270,6 +271,7 @@ public class ScopeApplicationAdapter ext
                                        log.error("Attempt of unauthorized room 
enter: USER not found, client is rejected");
                                        return rejectClient();
                                }
+                               rcm.setUsername(u.getLogin());
                                rcm.setFirstname(u.getFirstname());
                                rcm.setLastname(u.getLastname());
                                rcm.setEmail(u.getAddress() == null ? null : 
u.getAddress().getEmail());
@@ -319,7 +321,7 @@ public class ScopeApplicationAdapter ext
        }
 
        public Map<String, String> screenSharerAction(Map<String, Object> map) {
-               Map<String, String> returnMap = new HashMap<String, String>();
+               Map<String, String> returnMap = new HashMap<>();
                try {
                        log.debug("-----------  screenSharerAction ENTER");
                        IConnection current = Red5.getConnectionLocal();
@@ -377,7 +379,7 @@ public class ScopeApplicationAdapter ext
 
                        log.debug("checkScreenSharing -2- " + streamid);
 
-                       List<Client> screenSharerList = new 
LinkedList<Client>();
+                       List<Client> screenSharerList = new LinkedList<>();
 
                        Client currentClient = 
sessionManager.getClientByStreamId(streamid, null);
 
@@ -432,7 +434,7 @@ public class ScopeApplicationAdapter ext
                                client.setStreamPublishName("" + 
map.get("publishName"));
                                
sessionManager.updateClientByStreamId(current.getClient().getId(), client, 
false, null);
 
-                               Map<String, Object> returnMap = new 
HashMap<String, Object>();
+                               Map<String, Object> returnMap = new HashMap<>();
                                returnMap.put("alreadyPublished", false);
 
                                // if is already started screen sharing, then 
there is no need
@@ -509,7 +511,7 @@ public class ScopeApplicationAdapter ext
                                }
                        }
                }
-               return new ArrayList<Long>(broadcastList);
+               return new ArrayList<>(broadcastList);
        }
 
        /**
@@ -944,7 +946,7 @@ public class ScopeApplicationAdapter ext
                        currentClient.setMicMuted(mute);
                        
sessionManager.updateClientByStreamId(currentClient.getStreamid(), 
currentClient, false, null);
 
-                       HashMap<Integer, Object> newMessage = new 
HashMap<Integer, Object>();
+                       Map<Integer, Object> newMessage = new HashMap<>();
                        newMessage.put(0, "updateMuteStatus");
                        newMessage.put(1, currentClient);
                        sendMessageWithClient(newMessage);
@@ -1231,8 +1233,8 @@ public class ScopeApplicationAdapter ext
         * @param message
         * @return the list of room clients
         */
-       public HashMap<String, Client> sendMessageByRoomAndDomain(Long roomId, 
Object message) {
-               HashMap<String, Client> roomClientList = new HashMap<String, 
Client>();
+       public Map<String, Client> sendMessageByRoomAndDomain(Long roomId, 
Object message) {
+               Map<String, Client> roomClientList = new HashMap<>();
                try {
 
                        log.debug("sendMessageByRoomAndDomain " + roomId);
@@ -1441,7 +1443,7 @@ public class ScopeApplicationAdapter ext
                                
whiteboardManagement.addWhiteBoardObjectById(roomId, whiteboardObj, wbId);
                        }
 
-                       Map<String, Object> sendObject = new HashMap<String, 
Object>();
+                       Map<String, Object> sendObject = new HashMap<>();
                        sendObject.put("id", wbId);
                        sendObject.put("param", wbObj);
 
@@ -1666,7 +1668,7 @@ public class ScopeApplicationAdapter ext
                        IConnection current = Red5.getConnectionLocal();
                        Client currentClient = 
sessionManager.getClientByStreamId(current.getClient().getId(), null);
 
-                       HashMap<String, Object> hsm = new HashMap<String, 
Object>();
+                       Map<String, Object> hsm = new HashMap<>();
                        hsm.put("client", currentClient);
                        hsm.put("message", newMessage);
 
@@ -1692,7 +1694,7 @@ public class ScopeApplicationAdapter ext
                try {
                        log.debug("### sendMessageById ###" + clientId);
 
-                       HashMap<String, Object> hsm = new HashMap<String, 
Object>();
+                       Map<String, Object> hsm = new HashMap<>();
                        hsm.put("message", newMessage);
 
                        // broadcast Message to specific user with id inside 
the same Scope
@@ -1724,7 +1726,7 @@ public class ScopeApplicationAdapter ext
                        IConnection current = Red5.getConnectionLocal();
                        Client currentClient = 
sessionManager.getClientByStreamId(current.getClient().getId(), null);
 
-                       HashMap<String, Object> hsm = new HashMap<String, 
Object>();
+                       Map<String, Object> hsm = new HashMap<>();
                        hsm.put("client", currentClient);
                        hsm.put("message", newMessage);
 
@@ -1832,7 +1834,7 @@ public class ScopeApplicationAdapter ext
                        current_rcl.setIsRecording(true);
                        
sessionManager.updateClientByStreamId(current.getClient().getId(), current_rcl, 
false, null);
 
-                       Map<String, String> interviewStatus = new 
HashMap<String, String>();
+                       Map<String, String> interviewStatus = new HashMap<>();
                        interviewStatus.put("action", "start");
 
                        for (IConnection conn : 
current.getScope().getClientConnections()) {
@@ -1922,7 +1924,7 @@ public class ScopeApplicationAdapter ext
 
                        recordingService.stopRecordAndSave(scope, 
currentClient, clientRecordingId);
 
-                       Map<String, String> interviewStatus = new 
HashMap<String, String>();
+                       Map<String, String> interviewStatus = new HashMap<>();
                        interviewStatus.put("action", "stop");
 
                        sendMessageToCurrentScope("interviewStatus", 
interviewStatus, true);
@@ -1949,7 +1951,7 @@ public class ScopeApplicationAdapter ext
                } catch (Exception err) {
                        log.debug("[getClientListScope]", err);
                }
-               return new ArrayList<Client>();
+               return new ArrayList<>();
        }
 
        private boolean getWhiteboardDrawStatus() {
@@ -1976,7 +1978,7 @@ public class ScopeApplicationAdapter ext
         */
 
        private List<Long> getVerifiedActiveRoomIds(Server s) {
-               List<Long> result = new 
ArrayList<Long>(sessionManager.getActiveRoomIdsByServer(s));
+               List<Long> result = new 
ArrayList<>(sessionManager.getActiveRoomIdsByServer(s));
                //verify
                for (Iterator<Long> i = result.iterator(); i.hasNext();) {
                        Long id = i.next();

Modified: 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/session/store/DatabaseStore.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/session/store/DatabaseStore.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/session/store/DatabaseStore.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/session/store/DatabaseStore.java
 Wed Mar  1 06:11:13 2017
@@ -30,15 +30,15 @@ import org.apache.openmeetings.db.entity
 import org.springframework.beans.factory.annotation.Autowired;
 
 public class DatabaseStore implements IClientPersistenceStore {
-       
+
        @Autowired
        private ClientDao clientDao;
-       
+
        @Override
        public void clear() {
                clientDao.cleanAllClients();
        }
-       
+
        @Override
        public void put(String streamId, Client rcl) {
                if (rcl.getId() != null) {
@@ -65,20 +65,20 @@ public class DatabaseStore implements IC
 
        @Override
        public Map<Long, List<Client>> getClientsByPublicSID(String publicSID) {
-               Map<Long, List<Client>> returnMap = new HashMap<Long, 
List<Client>>();
+               Map<Long, List<Client>> returnMap = new HashMap<>();
                List<Client> clientList = 
clientDao.getClientsByPublicSID(publicSID);
                for (Client cl : clientList) {
                        if (cl.getServer() == null) {
                                List<Client> clList = returnMap.get(null);
                                if (clList == null) {
-                                       clList = new ArrayList<Client>();
+                                       clList = new ArrayList<>();
                                }
                                clList.add(cl);
                                returnMap.put(null, clList);
                        } else {
                                List<Client> clList = 
returnMap.get(cl.getServer().getId());
                                if (clList == null) {
-                                       clList = new ArrayList<Client>();
+                                       clList = new ArrayList<>();
                                }
                                clList.add(cl);
                                returnMap.put(cl.getServer().getId(), clList);
@@ -86,12 +86,12 @@ public class DatabaseStore implements IC
                }
                return returnMap;
        }
-       
+
        @Override
        public Collection<Client> getClients() {
                return clientDao.getClients();
        }
-       
+
        @Override
        public Collection<Client> getClientsWithServer() {
                return clientDao.getClientsWithServer();

Modified: 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/session/store/HashMapStore.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/session/store/HashMapStore.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/session/store/HashMapStore.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/session/store/HashMapStore.java
 Wed Mar  1 06:11:13 2017
@@ -37,7 +37,7 @@ import org.slf4j.Logger;
 /**
  * Stores the session in the memory.
  * Is NOT designed to be clustered across multiple servers.
- * 
+ *
  * <ul>
  * <li>client by streamid</li>
  * <li>client by publicSID</li>
@@ -45,20 +45,20 @@ import org.slf4j.Logger;
  * <li>clients by roomId</li>
  * <li>roomIds by server</li>
  * </ul>
- * 
+ *
  * @author sebawagner
- * 
+ *
  */
 public class HashMapStore implements IClientPersistenceStore {
        protected static final Logger log = 
Red5LoggerFactory.getLogger(HashMapStore.class, webAppRootKey);
-       
+
        private Map<String, Client> clientsByStreamId = new 
ConcurrentHashMap<>();
 
        @Override
        public void clear() {
                clientsByStreamId = new ConcurrentHashMap<>();
        }
-       
+
        @Override
        public void put(String streamId, Client rcl) {
                clientsByStreamId.put(rcl.getStreamid(), rcl);
@@ -73,7 +73,7 @@ public class HashMapStore implements ICl
        public Client get(Server server, String streamId) {
                return clientsByStreamId.get(streamId);
        }
-       
+
        @Override
        public List<Client> getClientsByPublicSID(Server server, String 
publicSID) {
                List<Client> clientList = new ArrayList<>();
@@ -85,7 +85,7 @@ public class HashMapStore implements ICl
                }
                return clientList;
        }
-       
+
        @Override
        public Map<Long,List<Client>> getClientsByPublicSID(String publicSID) {
                Map<Long,List<Client>> clientMapList = new HashMap<>();
@@ -99,24 +99,24 @@ public class HashMapStore implements ICl
                clientMapList.put(null, clientList);
                return clientMapList;
        }
-       
+
        @Override
        public Collection<Client> getClients() {
                return clientsByStreamId.values();
        }
-       
+
        @Override
        public Collection<Client> getClientsWithServer() {
                //there is no server object to be loaded, memory cache means
                //there is no cluster enabled
                return getClients();
        }
-       
+
        @Override
        public Collection<Client> getClientsByServer(Server server) {
                return clientsByStreamId.values();
        }
-       
+
        @Override
        public List<Client> getClientsByUserId(Server server, Long userId) {
                List<Client> clientList = new ArrayList<>();
@@ -128,7 +128,7 @@ public class HashMapStore implements ICl
                }
                return clientList;
        }
-       
+
        @Override
        public  List<Client> getClientsByRoomId(Long roomId) {
                List<Client> clientList = new ArrayList<>();
@@ -150,7 +150,7 @@ public class HashMapStore implements ICl
        public int size() {
                return clientsByStreamId.size();
        }
-       
+
        @Override
        public int sizeByServer(Server server) {
                return clientsByStreamId.size();
@@ -160,14 +160,14 @@ public class HashMapStore implements ICl
        public Collection<Client> values() {
                return clientsByStreamId.values();
        }
-       
+
        public int getTotalNumberOfSessions() {
                return clientsByStreamId.size();
        }
-       
+
        /**
         * Print some session statistics to the debug out
-        * 
+        *
         * @param detailLevel
         */
        public void printDebugInformation(List<DEBUG_DETAILS> detailLevel) {
@@ -201,7 +201,7 @@ public class HashMapStore implements ICl
                                rooms.add(roomId);
                        }
                }
-               return new ArrayList<Long>(rooms);
+               return new ArrayList<>(rooms);
        }
 
 }

Modified: 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/util/WebSocketHelper.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/util/WebSocketHelper.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/util/WebSocketHelper.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-core/src/main/java/org/apache/openmeetings/core/util/WebSocketHelper.java
 Wed Mar  1 06:11:13 2017
@@ -171,7 +171,7 @@ public class WebSocketHelper {
                IWebSocketConnectionRegistry reg = 
settings.getConnectionRegistry();
                Executor executor = settings.getWebSocketPushMessageExecutor();
                for (Client c : func.apply(app)) {
-                       if (check == null || (check != null && check.test(c))) {
+                       if (check == null || check.test(c)) {
                                final IWebSocketConnection wc = 
reg.getConnection(app, c.getSessionId(), new PageIdKey(c.getPageId()));
                                if (wc != null && wc.isOpen()) {
                                        executor.run(() -> consumer.accept(wc));

Modified: 
openmeetings/application/trunk/openmeetings-core/src/test/java/org/apache/openmeetings/test/rtmp/LoadTestRtmpClient.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-core/src/test/java/org/apache/openmeetings/test/rtmp/LoadTestRtmpClient.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-core/src/test/java/org/apache/openmeetings/test/rtmp/LoadTestRtmpClient.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-core/src/test/java/org/apache/openmeetings/test/rtmp/LoadTestRtmpClient.java
 Wed Mar  1 06:11:13 2017
@@ -53,16 +53,16 @@ public class LoadTestRtmpClient extends
                        this.ended = ended;
                }
        }
-       
+
        private int counterCalls = 0; // a call is always 2 steps
-       private Map<Integer, CallObject> calls = new HashMap<Integer, 
CallObject>();
+       private Map<Integer, CallObject> calls = new HashMap<>();
        private boolean isConnected = false;
        private final int instanceId;
 
        public LoadTestRtmpClient(int instanceId) {
                this.instanceId = instanceId;
        }
-       
+
        public boolean performCall() {
 
                // System.err.println("performCall " + isConnected);
@@ -70,7 +70,7 @@ public class LoadTestRtmpClient extends
                if (!isConnected) {
                        return false;
                }
-               
+
                if (counterCalls % 2 == 0) {
 
                        if (counterCalls > 10) {
@@ -82,7 +82,7 @@ public class LoadTestRtmpClient extends
                        System.err.println("Rest o do new call " + 
counterCalls);
                        counterCalls++;
 
-                       Map<String, Integer> map = new HashMap<String, 
Integer>();
+                       Map<String, Integer> map = new HashMap<>();
                        map.put("instanceId", instanceId);
                        map.put("count", counterCalls);
                        calls.put(counterCalls, new CallObject(new Date()));
@@ -91,12 +91,12 @@ public class LoadTestRtmpClient extends
                } else {
                        System.err.println("Call running " + counterCalls);
                }
-               
-               
-               
+
+
+
                return false;
        }
-       
+
        public double getAverageTime() {
                long overallTime = 0L;
 
@@ -117,7 +117,7 @@ public class LoadTestRtmpClient extends
 
                return averageTime;
        }
-       
+
        @Override
        public void resultReceived(IPendingServiceCall call) {
                String method = call == null ? null : 
call.getServiceMethodName();
@@ -162,11 +162,11 @@ public class LoadTestRtmpClient extends
        @Override
        public void onStreamEvent(Notify notify) {
                // TODO Auto-generated method stub
-               
+
        }
 
        public int getNumberOfCalls() {
                return calls.size();
        }
-       
+
 }

Modified: 
openmeetings/application/trunk/openmeetings-core/src/test/java/org/apache/openmeetings/test/rtmp/SimulateLoadTest.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-core/src/test/java/org/apache/openmeetings/test/rtmp/SimulateLoadTest.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-core/src/test/java/org/apache/openmeetings/test/rtmp/SimulateLoadTest.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-core/src/test/java/org/apache/openmeetings/test/rtmp/SimulateLoadTest.java
 Wed Mar  1 06:11:13 2017
@@ -30,7 +30,7 @@ import org.slf4j.Logger;
 public class SimulateLoadTest {
        private static final Logger log = 
Red5LoggerFactory.getLogger(SimulateLoadTest.class, webAppRootKey);
        private int numberOfClients = 25;
-       private List<SimulateLoad> simulateLoadList = new 
ArrayList<SimulateLoad>();
+       private List<SimulateLoad> simulateLoadList = new ArrayList<>();
 
        private String host = "192.168.1.7";
        private final int port = 1935;

Modified: 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/basic/ConfigurationDao.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/basic/ConfigurationDao.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/basic/ConfigurationDao.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/basic/ConfigurationDao.java
 Wed Mar  1 06:11:13 2017
@@ -18,6 +18,7 @@
  */
 package org.apache.openmeetings.db.dao.basic;
 
+import static 
org.apache.openmeetings.util.OpenmeetingsVariables.APPLICATION_NAME;
 import static 
org.apache.openmeetings.util.OpenmeetingsVariables.CONFIG_APPLICATION_BASE_URL;
 import static 
org.apache.openmeetings.util.OpenmeetingsVariables.CONFIG_APPLICATION_NAME;
 import static 
org.apache.openmeetings.util.OpenmeetingsVariables.CONFIG_CRYPT_KEY;
@@ -27,7 +28,6 @@ import static org.apache.openmeetings.ut
 import static 
org.apache.openmeetings.util.OpenmeetingsVariables.configKeyCryptClassName;
 import static org.apache.openmeetings.util.OpenmeetingsVariables.webAppRootKey;
 import static 
org.apache.openmeetings.util.OpenmeetingsVariables.whiteboardDrawStatus;
-import static 
org.apache.openmeetings.util.OpenmeetingsVariables.APPLICATION_NAME;
 
 import java.lang.reflect.Constructor;
 import java.util.ArrayList;
@@ -55,9 +55,9 @@ import org.springframework.transaction.a
  * {@link #getConfValue(String, Class, String)} <br/>
  * <br/>
  * <b> {@link #get(String)} is deprecated!</b>
- * 
+ *
  * @author swagner
- * 
+ *
  */
 @Transactional
 public class ConfigurationDao implements IDataProviderDao<Configuration> {
@@ -74,7 +74,7 @@ public class ConfigurationDao implements
 
        /**
         * Retrieves Configuration regardless of its deleted status
-        * 
+        *
         * @param confKey
         * @return
         */
@@ -90,8 +90,8 @@ public class ConfigurationDao implements
        }
 
        public List<Configuration> get(String... keys) {
-               List<Configuration> result = new ArrayList<Configuration>();
-               for (String key : keys) { //iteration is necessary to fill list 
with all values 
+               List<Configuration> result = new ArrayList<>();
+               for (String key : keys) { //iteration is necessary to fill list 
with all values
                        List<Configuration> r = 
em.createNamedQuery("getConfigurationsByKeys", Configuration.class)
                                        .setParameter("keys", 
Arrays.asList(key))
                                        .getResultList();
@@ -103,9 +103,9 @@ public class ConfigurationDao implements
        /**
         * Return a object using a custom type and a default value if the key 
is not
         * present, or value is not set
-        * 
+        *
         * Example: Integer my_key = getConfValue("my_key", Integer.class, 
"15");
-        * 
+        *
         * @param key
         * @param type
         * @param defaultValue
@@ -196,7 +196,7 @@ public class ConfigurationDao implements
        public Configuration get(long id) {
                return get(Long.valueOf(id));
        }
-       
+
        @Override
        public Configuration get(Long id) {
                if (id == null) {
@@ -219,7 +219,7 @@ public class ConfigurationDao implements
                q.setMaxResults(count);
                return q.getResultList();
        }
-       
+
        @Override
        public long count() {
                return em.createNamedQuery("countConfigurations", 
Long.class).getSingleResult();
@@ -230,12 +230,12 @@ public class ConfigurationDao implements
                TypedQuery<Long> q = 
em.createQuery(DaoHelper.getSearchQuery("Configuration", "c", search, true, 
true, null, searchFields), Long.class);
                return q.getSingleResult();
        }
-       
+
        @Override
        public Configuration update(Configuration entity, Long userId) {
                return update(entity, userId, false);
        }
-       
+
        public Configuration update(Configuration entity, Long userId, boolean 
deleted) {
                String key = entity.getKey();
                String value = entity.getValue();
@@ -270,7 +270,7 @@ public class ConfigurationDao implements
 
        /**
         * returns the max upload size configured by max_upload_size config key
-        * 
+        *
         * @param configurationDao
         * @return
         */
@@ -282,7 +282,7 @@ public class ConfigurationDao implements
                }
                return DEFAULT_MAX_UPLOAD_SIZE;
        }
-       
+
        public String getCryptKey() {
                if (configKeyCryptClassName == null) {
                        String cryptClass = getConfValue(CONFIG_CRYPT_KEY, 
String.class, null);

Modified: 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/calendar/AppointmentDao.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/calendar/AppointmentDao.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/calendar/AppointmentDao.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/calendar/AppointmentDao.java
 Wed Mar  1 06:11:13 2017
@@ -111,7 +111,7 @@ public class AppointmentDao {
                }
                roomDao.update(r, userId);
                if (sendmails) {
-                       Set<Long> mmIds = a.getId() == null ? new 
HashSet<Long>()
+                       Set<Long> mmIds = a.getId() == null ? new HashSet<>()
                                        : 
meetingMemberDao.getMeetingMemberIdsByAppointment(a.getId());
                        // update meeting members
                        Appointment a0 = a.getId() == null ? null : 
get(a.getId());

Modified: 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/calendar/MeetingMemberDao.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/calendar/MeetingMemberDao.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/calendar/MeetingMemberDao.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/calendar/MeetingMemberDao.java
 Wed Mar  1 06:11:13 2017
@@ -57,11 +57,11 @@ public class MeetingMemberDao {
        public Set<Long> getMeetingMemberIdsByAppointment(Long appointmentId) {
                log.debug("getMeetingMemberIdsByAppointment: " + appointmentId);
 
-               return new 
HashSet<Long>(em.createNamedQuery("getMeetingMemberIdsByAppointment", 
Long.class)
+               return new 
HashSet<>(em.createNamedQuery("getMeetingMemberIdsByAppointment", Long.class)
                                .setParameter("id", appointmentId)
                                .getResultList());
        }
-       
+
        /**
         * Updating MeetingMember
         */

Modified: 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/label/LabelDao.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/label/LabelDao.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/label/LabelDao.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/label/LabelDao.java
 Wed Mar  1 06:11:13 2017
@@ -61,11 +61,11 @@ import org.xml.sax.SAXException;
 import org.xml.sax.XMLReader;
 
 /**
- * 
+ *
  * CRUD operations for {@link StringLabel}
- * 
+ *
  * @author solomax, swagner
- * 
+ *
  */
 public class LabelDao implements IDataProviderDao<StringLabel>{
        private static final Logger log = 
Red5LoggerFactory.getLogger(LabelDao.class, webAppRootKey);
@@ -73,13 +73,13 @@ public class LabelDao implements IDataPr
        private static final String KEY_ATTR = "key";
        public static final String APP_RESOURCES_EN = 
"Application.properties.xml";
        public static final String APP_RESOURCES = 
"Application_%s.properties.xml";
-       public static final LinkedHashMap<Long, Locale> languages = new 
LinkedHashMap<Long, Locale>(); //TODO hide it and return unmodifiable map
-       public static final ConcurrentHashMap<Locale, List<StringLabel>> 
labelCache = new ConcurrentHashMap<Locale, List<StringLabel>>();
-       public static final Set<String> keys = new HashSet<String>();
+       public static final LinkedHashMap<Long, Locale> languages = new 
LinkedHashMap<>(); //TODO hide it and return unmodifiable map
+       public static final ConcurrentHashMap<Locale, List<StringLabel>> 
labelCache = new ConcurrentHashMap<>();
+       public static final Set<String> keys = new HashSet<>();
        private static Class<?> APP = null;
 
        public List<Map<String, Object>> getStrings(Long language_id, int 
start, int count) {
-               List<Map<String, Object>> result = new ArrayList<Map<String, 
Object>>();
+               List<Map<String, Object>> result = new ArrayList<>();
                for (int i = 0; i < count; ++i) {
                        Map<String, Object> map = new HashMap<>();
                        map.put("id", start + i);
@@ -88,7 +88,7 @@ public class LabelDao implements IDataPr
                }
                return result;
        }
-       
+
        private static void storeLanguages() throws Exception {
                Document d = XmlExport.createDocument();
                Element r = XmlExport.createRoot(d, "language");
@@ -97,7 +97,7 @@ public class LabelDao implements IDataPr
                }
                XmlExport.toXml(getLangFile(), d);
        }
-       
+
        public static void add(Locale l) throws Exception {
                long id = 0L;
                for (Map.Entry<Long, Locale> e : languages.entrySet()) {
@@ -107,7 +107,7 @@ public class LabelDao implements IDataPr
                storeLanguages();
                labelCache.put(l, new ArrayList<StringLabel>());
        }
-       
+
        public String getString(long fieldValuesId, long langId) {
                return ensureApplication(langId).getOmString(fieldValuesId, 
langId);
        }
@@ -119,7 +119,7 @@ public class LabelDao implements IDataPr
        private static File getLangFile() {
                return new File(OmFileHelper.getLanguagesDir(), 
OmFileHelper.nameOfLanguageFile);
        }
-       
+
        public static synchronized Class<?> getAppClass() throws 
ClassNotFoundException {
                if (APP == null) {
                        //FIXME HACK to resolve package dependencies
@@ -127,7 +127,7 @@ public class LabelDao implements IDataPr
                }
                return APP;
        }
-       
+
        public static void initLanguageMap() {
                SAXReader reader = new SAXReader();
                try {
@@ -156,7 +156,7 @@ public class LabelDao implements IDataPr
                }
                return name;
        }
-       
+
        private static void storeLabels(Locale l) throws Exception {
                Document d = XmlExport.createDocument();
                Element r = XmlExport.createRoot(d);
@@ -167,7 +167,7 @@ public class LabelDao implements IDataPr
                URL u = APP.getResource(getLabelFileName(l));
                XmlExport.toXml(new File(u.toURI()), d);
        }
-       
+
        public static void upload(Locale l, InputStream is) throws Exception {
                List<StringLabel> labels = getLabels(is);
                URL u = APP.getResource(getLabelFileName(Locale.ENGLISH)); 
//get the URL of existing resource
@@ -179,9 +179,9 @@ public class LabelDao implements IDataPr
                labelCache.put(l, labels);
                storeLabels(l);
        }
-       
+
        private static List<StringLabel> getLabels(Locale l) {
-               List<StringLabel> labels = new ArrayList<StringLabel>();
+               List<StringLabel> labels = new ArrayList<>();
                try (InputStream is = 
APP.getResourceAsStream(getLabelFileName(l))) {
                        labels = getLabels(is);
                } catch (Exception e) {
@@ -189,9 +189,9 @@ public class LabelDao implements IDataPr
                }
                return labels;
        }
-       
+
        private static List<StringLabel> getLabels(InputStream is) throws 
Exception {
-               final List<StringLabel> labels = new ArrayList<StringLabel>();
+               final List<StringLabel> labels = new ArrayList<>();
                SAXParserFactory spf = SAXParserFactory.newInstance();
                spf.setNamespaceAware(true);
                try {
@@ -199,45 +199,45 @@ public class LabelDao implements IDataPr
                        XMLReader xr = parser.getXMLReader();
                        xr.setContentHandler(new ContentHandler() {
                                StringLabel label = null;
-                               
+
                                @Override
                                public void startPrefixMapping(String prefix, 
String uri) throws SAXException {}
-                               
+
                                @Override
                                public void startElement(String uri, String 
localName, String qName, Attributes atts) throws SAXException {
                                        if (ENTRY_ELEMENT.equals(localName)) {
                                                label = new 
StringLabel(atts.getValue(KEY_ATTR), "");
                                        }
                                }
-                               
+
                                @Override
                                public void startDocument() throws SAXException 
{}
-                               
+
                                @Override
                                public void skippedEntity(String name) throws 
SAXException {}
-                               
+
                                @Override
                                public void setDocumentLocator(Locator locator) 
{}
-                               
+
                                @Override
                                public void processingInstruction(String 
target, String data) throws SAXException {}
-                               
+
                                @Override
                                public void ignorableWhitespace(char[] ch, int 
start, int length) throws SAXException {}
-                               
+
                                @Override
                                public void endPrefixMapping(String prefix) 
throws SAXException {}
-                               
+
                                @Override
                                public void endElement(String uri, String 
localName, String qName) throws SAXException {
                                        if (ENTRY_ELEMENT.equals(localName)) {
                                                labels.add(label);
                                        }
                                }
-                               
+
                                @Override
                                public void endDocument() throws SAXException {}
-                               
+
                                @Override
                                public void characters(char[] ch, int start, 
int length) throws SAXException {
                                        StringBuilder sb = new 
StringBuilder(label.getValue());
@@ -251,7 +251,7 @@ public class LabelDao implements IDataPr
                }
                return labels;
        }
-       
+
        private static List<StringLabel> getLabels(Locale l, final String 
search) {
                if (!labelCache.containsKey(l)) {
                        List<StringLabel> ll = getLabels(l);
@@ -270,7 +270,7 @@ public class LabelDao implements IDataPr
                }
                return result;
        }
-       
+
        @Override
        public StringLabel get(long id) {
                throw new RuntimeException("Should not be used");
@@ -314,7 +314,7 @@ public class LabelDao implements IDataPr
                }
                return result.subList(start, start + count > result.size() ? 
result.size() : start + count);
        }
-       
+
        @Override
        public long count() {
                throw new RuntimeException("Should not be used");
@@ -343,12 +343,12 @@ public class LabelDao implements IDataPr
                storeLabels(l);
                return entity;
        }
-       
+
        @Override
        public void delete(StringLabel entity, Long userId) {
                throw new RuntimeException("Should not be used");
        }
-       
+
        public void delete(Locale l, StringLabel entity) throws Exception {
                List<StringLabel> labels = labelCache.get(l);
                if (labels.contains(entity)) {

Modified: 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/room/ClientDao.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/room/ClientDao.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/room/ClientDao.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/room/ClientDao.java
 Wed Mar  1 06:11:13 2017
@@ -32,18 +32,18 @@ import org.springframework.transaction.a
 
 /**
  * Persistence of client objects to database is only available if so 
configured!
- * 
+ *
  * @author sebawagner
  *
  */
 @Transactional
 public class ClientDao {
-       
+
        @PersistenceContext
        private EntityManager em;
-       
-       private static List<Long> EMPTY_LIST = new ArrayList<Long>(0);
-       
+
+       private static List<Long> EMPTY_LIST = new ArrayList<>(0);
+
        public void cleanAllClients() {
                em.createNamedQuery("deleteAll").executeUpdate();
        }
@@ -53,34 +53,34 @@ public class ClientDao {
                        setParameter("server", server).
                        executeUpdate();
        }
-       
+
        public Client add(Client entity) {
                em.persist(entity);
                return entity;
        }
-       
+
        public Client update(Client entity) {
                em.merge(entity);
                return entity;
        }
-       
+
        public void delete(Client entity) {
                Query q = em.createNamedQuery("deletedById");
                q.setParameter("id", entity.getId());
                q.executeUpdate();
        }
-       
+
        public void removeClientByServerAndStreamId(Server server, String 
streamId) {
                Query q = em.createNamedQuery("deletedByServerAndStreamId");
                q.setParameter("server", server);
                q.setParameter("streamid", streamId);
                q.executeUpdate();
        }
-       
+
        public int countClients() {
                return em.createNamedQuery("countClients", 
Long.class).getSingleResult().intValue();
        }
-       
+
        public int countClientsByServer(Server server) {
                TypedQuery<Long> q = 
em.createNamedQuery("countClientsByServer", Long.class);
                q.setParameter("server", server);
@@ -95,9 +95,9 @@ public class ClientDao {
        }
 
        /**
-        * Query.getSingleResult would throw an error if result is null, 
+        * Query.getSingleResult would throw an error if result is null,
         * see: 
http://stackoverflow.com/questions/2002993/jpa-getsingleresult-or-null
-        * 
+        *
         * @param server
         * @param streamId
         * @return
@@ -130,14 +130,14 @@ public class ClientDao {
 
        public List<Client> getClientsByServer(Server server) {
                TypedQuery<Client> q = 
em.createNamedQuery("getClientsByServer", Client.class);
-               q.setParameter("server", server);       
+               q.setParameter("server", server);
                return q.getResultList();
        }
 
        public List<Client> getClients() {
                return em.createNamedQuery("getClients", 
Client.class).getResultList();
        }
-       
+
        public List<Client> getClientsWithServer() {
                return em.createNamedQuery("getClientsWithServer", 
Client.class).getResultList();
        }
@@ -145,19 +145,19 @@ public class ClientDao {
        public List<Client> getClientsByUserId(Server server, Long userId) {
                TypedQuery<Client> q = 
em.createNamedQuery("getClientsByUserId", Client.class);
                q.setParameter("server", server);
-               q.setParameter("userId", userId);       
+               q.setParameter("userId", userId);
                return q.getResultList();
        }
 
        public List<Client> getClientsByRoomId(Long roomId) {
                TypedQuery<Client> q = 
em.createNamedQuery("getClientsByRoomId", Client.class);
-               q.setParameter("roomId", roomId);       
+               q.setParameter("roomId", roomId);
                return q.getResultList();
        }
 
        /**
         * returns a list of servers or an empty list in case no roomIds are 
found
-        * 
+        *
         * @param server
         * @return
         */
@@ -166,7 +166,7 @@ public class ClientDao {
                q.setParameter("server", server);
                @SuppressWarnings("unchecked")
                List<Long> resultList = q.getResultList();
-               //if the result list contains only a value null, it means it 
+               //if the result list contains only a value null, it means it
                //was empty and no roomid's have been found
                if (resultList.size() == 1 && resultList.get(0) == null) {
                        return EMPTY_LIST;

Modified: 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/server/LdapConfigDao.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/server/LdapConfigDao.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/server/LdapConfigDao.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/server/LdapConfigDao.java
 Wed Mar  1 06:11:13 2017
@@ -41,10 +41,10 @@ import org.springframework.transaction.a
 
 /**
  * Insert/Update/Delete {@link LdapConfig}
- * 
- * 
+ *
+ *
  * @author swagner
- * 
+ *
  */
 @Transactional
 public class LdapConfigDao implements IDataProviderDao<LdapConfig> {
@@ -61,7 +61,7 @@ public class LdapConfigDao implements ID
        public LdapConfig get(long id) {
                return get(Long.valueOf(id));
        }
-       
+
        @Override
        public LdapConfig get(Long id) {
                try {
@@ -96,11 +96,11 @@ public class LdapConfigDao implements ID
        public List<LdapConfig> get() {
                //Add localhost Domain
                LdapConfig ldapConfig = new LdapConfig();
-               
+
                ldapConfig.setName("local DB [internal]");
                ldapConfig.setId(-1L);
 
-               List<LdapConfig> result = new ArrayList<LdapConfig>();
+               List<LdapConfig> result = new ArrayList<>();
                result.add(ldapConfig);
                result.addAll(getActive());
                return result;
@@ -121,7 +121,7 @@ public class LdapConfigDao implements ID
                q.setMaxResults(count);
                return q.getResultList();
        }
-       
+
        @Override
        public long count() {
                try {
@@ -140,7 +140,7 @@ public class LdapConfigDao implements ID
                TypedQuery<Long> q = 
em.createQuery(DaoHelper.getSearchQuery("LdapConfig", "lc", search, true, true, 
null, searchFields), Long.class);
                return q.getSingleResult();
        }
-       
+
        @Override
        public LdapConfig update(LdapConfig entity, Long userId) {
                try {

Modified: 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/user/UserDao.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/user/UserDao.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/user/UserDao.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dao/user/UserDao.java
 Wed Mar  1 06:11:13 2017
@@ -89,7 +89,7 @@ public class UserDao implements IGroupAd
        private TimezoneUtil timezoneUtil;
 
        public static Set<Right> getDefaultRights() {
-               Set<Right> rights = new HashSet<User.Right>();
+               Set<Right> rights = new HashSet<>();
                rights.add(Right.Login);
                rights.add(Right.Dashboard);
                rights.add(Right.Room);
@@ -157,7 +157,7 @@ public class UserDao implements IGroupAd
        }
 
        public List<User> get(String search, int start, int count, String sort, 
boolean filterContacts, Long currentUserId) {
-               Map<String, Object> params = new HashMap<String, Object>();
+               Map<String, Object> params = new HashMap<>();
                TypedQuery<User> q = 
em.createQuery(DaoHelper.getSearchQuery("User", "u", 
getAdditionalJoin(filterContacts), search, true, true, false
                                , getAdditionalWhere(filterContacts, 
currentUserId, params), sort, searchFields), User.class);
                q.setFirstResult(start);
@@ -193,7 +193,7 @@ public class UserDao implements IGroupAd
        }
 
        public long count(String search, boolean filterContacts, Long 
currentUserId) {
-               Map<String, Object> params = new HashMap<String, Object>();
+               Map<String, Object> params = new HashMap<>();
                TypedQuery<Long> q = 
em.createQuery(DaoHelper.getSearchQuery("User", "u", 
getAdditionalJoin(filterContacts), search, true, true, true
                                , getAdditionalWhere(filterContacts, 
currentUserId, params), null, searchFields), Long.class);
                setAdditionalParams(q, params);
@@ -210,7 +210,7 @@ public class UserDao implements IGroupAd
 
        //This is AdminDao method
        public List<User> get(String search, boolean excludeContacts, int 
first, int count) {
-               Map<String, Object> params = new HashMap<String, Object>();
+               Map<String, Object> params = new HashMap<>();
                TypedQuery<User> q = 
em.createQuery(DaoHelper.getSearchQuery("User", "u", null, search, true, true, 
false
                                , getAdditionalWhere(excludeContacts, params), 
null, searchFields), User.class);
                setAdditionalParams(q, params);
@@ -220,7 +220,7 @@ public class UserDao implements IGroupAd
        }
 
        public List<User> get(String search, boolean filterContacts, Long 
currentUserId) {
-               Map<String, Object> params = new HashMap<String, Object>();
+               Map<String, Object> params = new HashMap<>();
                TypedQuery<User> q = 
em.createQuery(DaoHelper.getSearchQuery("User", "u", 
getAdditionalJoin(filterContacts), search, true, true, false
                                , getAdditionalWhere(filterContacts, 
currentUserId, params), null, searchFields), User.class);
                setAdditionalParams(q, params);
@@ -530,7 +530,7 @@ public class UserDao implements IGroupAd
        }
 
        private <T> TypedQuery<T> getUserProfileQuery(Class<T> clazz, Long 
userId, String text, String offers, String search, String orderBy, boolean asc) 
{
-               Map<String, Object> params = new HashMap<String, Object>();
+               Map<String, Object> params = new HashMap<>();
                boolean filterContacts = true;
                boolean count = clazz.isAssignableFrom(Long.class);
 
@@ -592,7 +592,7 @@ public class UserDao implements IGroupAd
        }
 
        public Set<Right> getRights(Long id) {
-               Set<Right> rights = new HashSet<Right>();
+               Set<Right> rights = new HashSet<>();
 
                if (id == null) {
                        return rights;

Modified: 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dto/room/RoomSearchResult.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dto/room/RoomSearchResult.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dto/room/RoomSearchResult.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dto/room/RoomSearchResult.java
 Wed Mar  1 06:11:13 2017
@@ -31,12 +31,12 @@ public class RoomSearchResult {
        private Long errorId;
 
        public RoomSearchResult() {}
-       
+
        public RoomSearchResult(SearchResult<Room> copy) {
                if (copy != null) {
                        this.objectName = copy.getObjectName();
                        this.records = copy.getRecords();
-                       this.result = new 
ArrayList<RoomDTO>(copy.getResult().size());
+                       this.result = new ArrayList<>(copy.getResult().size());
                        for (Room r : copy.getResult()) {
                                result.add(new RoomDTO(r));
                        }

Modified: 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dto/user/UserSearchResult.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dto/user/UserSearchResult.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dto/user/UserSearchResult.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/dto/user/UserSearchResult.java
 Wed Mar  1 06:11:13 2017
@@ -29,19 +29,19 @@ public class UserSearchResult {
        private Long records;
        private List<UserDTO> result;
        private Long errorId;
-       
+
        public UserSearchResult() {}
 
        public UserSearchResult(SearchResult<User> copy) {
                this.objectName = copy.getObjectName();
                this.records = copy.getRecords();
-               this.result = new ArrayList<UserDTO>(copy.getResult().size());
+               this.result = new ArrayList<>(copy.getResult().size());
                for (User u : copy.getResult()) {
                        result.add(new UserDTO(u));
                }
                this.errorId = copy.getErrorId();
        }
-       
+
        public String getObjectName() {
                return objectName;
        }

Modified: 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/entity/room/Room.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/entity/room/Room.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/entity/room/Room.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/entity/room/Room.java
 Wed Mar  1 06:11:13 2017
@@ -282,7 +282,7 @@ public class Room implements IDataProvid
        @JoinColumn(name = "roomId")
        @ForeignKey(enabled = true)
        @ElementList(name = "room_moderators", required=false)
-       private List<RoomModerator> moderators = new ArrayList<RoomModerator>();
+       private List<RoomModerator> moderators = new ArrayList<>();
 
        @Column(name = "sip_enabled", nullable = false)
        @Element(data = true, required = false)

Modified: 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/entity/room/RoomPoll.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/entity/room/RoomPoll.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/entity/room/RoomPoll.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-db/src/main/java/org/apache/openmeetings/db/entity/room/RoomPoll.java
 Wed Mar  1 06:11:13 2017
@@ -65,30 +65,30 @@ public class RoomPoll implements IDataPr
        private static final long serialVersionUID = 1L;
        public static final int YES_NO_TYPE_ID = 1;
        public static final int NUMERIC_TYPE_ID = 2;
-       
+
        @XmlType(namespace="org.apache.openmeetings.room.poll.type")
        public enum Type {
                yesNo
                , numeric;
                private int id;
-               
+
                Type() {} //default;
                Type(int id) {
                        this.id = id;
                }
-               
+
                public int getId() {
                        return id;
                }
-               
+
                public static Type get(Long type) {
                        return get(type == null ? 1 : type.intValue());
                }
-               
+
                public static Type get(Integer type) {
                        return get(type == null ? 1 : type.intValue());
                }
-               
+
                public static Type get(int type) {
                        Type rt = Type.yesNo;
                        switch (type) {
@@ -101,16 +101,16 @@ public class RoomPoll implements IDataPr
                        return rt;
                }
        }
-       
+
        @Id
        @GeneratedValue(strategy = GenerationType.IDENTITY)
        @Column(name = "id")
        private Long id;
-       
+
        @Column(name = "name")
        @Element(name = "pollname", data = true, required = false)
        private String name;
-       
+
        @Column(name = "question")
        @Element(name = "pollquestion", data = true, required = false)
        private String question;
@@ -122,12 +122,12 @@ public class RoomPoll implements IDataPr
        @Column(name = "archived", nullable = false)
        @Element(data = true, required = false)
        private boolean archived;
-       
+
        @Column(name = "type")
        @Element(name = "polltypeid", data = true, required = false)
        @Enumerated(EnumType.STRING)
        private Type type;
-       
+
        @OneToOne(fetch = FetchType.EAGER)
        @JoinColumn(name = "user_id")
        @ForeignKey(enabled = true)
@@ -195,7 +195,7 @@ public class RoomPoll implements IDataPr
         */
        public List<RoomPollAnswer> getAnswers() {
                if (answers == null) {
-                       answers = new LinkedList<RoomPollAnswer>();
+                       answers = new LinkedList<>();
                }
                return answers;
        }

Modified: 
openmeetings/application/trunk/openmeetings-install/src/main/java/org/apache/openmeetings/cli/OmHelpFormatter.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-install/src/main/java/org/apache/openmeetings/cli/OmHelpFormatter.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-install/src/main/java/org/apache/openmeetings/cli/OmHelpFormatter.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-install/src/main/java/org/apache/openmeetings/cli/OmHelpFormatter.java
 Wed Mar  1 06:11:13 2017
@@ -36,12 +36,12 @@ import org.apache.commons.cli.Options;
 public class OmHelpFormatter extends HelpFormatter {
        private static String GENERAL_OPTION_GROUP = "";
        private int maxPrefixLength = 0;
-       
+
        @SuppressWarnings("unchecked")
        private static List<OmOption> getReqOptions(Options opts) {
                //suppose we have only 1 group (for now)
                OptionGroup g = 
((List<OptionGroup>)opts.getRequiredOptions()).get(0);
-               List<OmOption> result = new ArrayList<OmOption>();
+               List<OmOption> result = new ArrayList<>();
                for (Option o : g.getOptions()) {
                        result.add((OmOption)o);
                }
@@ -53,13 +53,13 @@ public class OmHelpFormatter extends Hel
                });
                return result;
        }
-       
-       private LinkedHashMap<String, List<OmOption>> getOptions(Options opts, 
int leftPad) {
+
+       private Map<String, List<OmOption>> getOptions(Options opts, int 
leftPad) {
                final String longOptSeparator = " ";
                final String lpad = createPadding(leftPad);
                final String lpadParam = createPadding(leftPad + 2);
                List<OmOption> reqOptions = getReqOptions(opts);
-               LinkedHashMap<String, List<OmOption>> map = new 
LinkedHashMap<String, List<OmOption>>(reqOptions.size());
+               Map<String, List<OmOption>> map = new 
LinkedHashMap<>(reqOptions.size());
                map.put(GENERAL_OPTION_GROUP, new ArrayList<OmOption>());
                for (OmOption o : reqOptions) {
                        map.put(o.getOpt(), new ArrayList<OmOption>());
@@ -69,7 +69,7 @@ public class OmHelpFormatter extends Hel
                        //TODO need better check (required option should go 
first and should not be duplicated
                        boolean skipOption = map.containsKey(o.getOpt());
                        boolean mainOption = skipOption || o.getGroup() == null;
-                       
+
                        // first create list containing only <lpad>-a,--aaa 
where
                        // -a is opt and --aaa is long opt; in parallel look for
                        // the longest opt string this list will be then used to
@@ -103,7 +103,7 @@ public class OmHelpFormatter extends Hel
 
                        o.setHelpPrefix(optBuf);
                        maxPrefixLength = Math.max(optBuf.length(), 
maxPrefixLength);
-                       
+
                        if (skipOption) {
                                //TODO need better check (required option 
should go first and should not be duplicated
                                continue;
@@ -125,7 +125,7 @@ public class OmHelpFormatter extends Hel
                                        boolean o2opt = !o2.isOptional(key);
                                        return (o1opt && o2opt || !o1opt && 
!o2opt) ? (o1.getOpt() == null ? 1 : -1) : (o1opt ? -1 : 1);
                                }
-                               
+
                        });
                        if (opts.hasOption(key)) {
                                options.add(0, (OmOption)opts.getOption(key));
@@ -133,7 +133,7 @@ public class OmHelpFormatter extends Hel
                }
                return map;
        }
-       
+
        private static StringBuilder getReqOptionsString(Options opts) {
                String delim = "";
                StringBuilder result = new StringBuilder();
@@ -143,13 +143,13 @@ public class OmHelpFormatter extends Hel
                }
                return result;
        }
-       
+
        @Override
        protected StringBuffer renderOptions(StringBuffer sb, int width, 
Options options, int leftPad, int descPad) {
                final String dpad = createPadding(descPad);
                final String optional = "(optional) ";
 
-               LinkedHashMap<String, List<OmOption>> optList = 
getOptions(options, leftPad);
+               Map<String, List<OmOption>> optList = getOptions(options, 
leftPad);
 
                char[] delimiter = new char[width - 2];
                Arrays.fill(delimiter, '-');

Modified: 
openmeetings/application/trunk/openmeetings-install/src/main/java/org/apache/openmeetings/cli/OmOption.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-install/src/main/java/org/apache/openmeetings/cli/OmOption.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-install/src/main/java/org/apache/openmeetings/cli/OmOption.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-install/src/main/java/org/apache/openmeetings/cli/OmOption.java
 Wed Mar  1 06:11:13 2017
@@ -76,10 +76,10 @@ public class OmOption extends Option {
        public void setOptional(boolean val) {
                setOptional(group, val);
        }
-       
+
        public void setOptional(String group, boolean val) {
                String[] grps = group.split(",");
-               optional = new HashMap<String, Boolean>(grps.length);
+               optional = new HashMap<>(grps.length);
                for(String g : grps) {
                        optional.put(g, val);
                }

Modified: 
openmeetings/application/trunk/openmeetings-screenshare/src/main/java/org/apache/openmeetings/screenshare/CaptureScreen.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-screenshare/src/main/java/org/apache/openmeetings/screenshare/CaptureScreen.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-screenshare/src/main/java/org/apache/openmeetings/screenshare/CaptureScreen.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-screenshare/src/main/java/org/apache/openmeetings/screenshare/CaptureScreen.java
 Wed Mar  1 06:11:13 2017
@@ -25,6 +25,7 @@ import static org.quartz.SimpleScheduleB
 import static org.slf4j.LoggerFactory.getLogger;
 
 import java.io.IOException;
+import java.util.Queue;
 import java.util.concurrent.ArrayBlockingQueue;
 import java.util.concurrent.atomic.AtomicBoolean;
 import java.util.concurrent.atomic.AtomicInteger;
@@ -58,7 +59,7 @@ public class CaptureScreen extends Threa
        private volatile boolean active = true;
        private IScreenEncoder se;
        private IScreenShare client;
-       private ArrayBlockingQueue<VideoData> frames = new 
ArrayBlockingQueue<VideoData>(2);
+       private Queue<VideoData> frames = new ArrayBlockingQueue<>(2);
        private String host = null;
        private String app = null;
        private int port = -1;
@@ -132,14 +133,14 @@ public class CaptureScreen extends Threa
                        log.error("Error while running: ", e);
                }
        }
-       
+
        /*
        private void pushAudio(byte[] audio, long ts) {
                if (startPublish) {
                        buffer.put((byte) 6);
                        buffer.put(audio);
                        buffer.flip();
-       
+
                        // I can stream audio
                        //packets successfully using linear PCM at 11025Hz. For 
those packets I
                        //push one byte (0x06) which specifies the format of 
audio data in a
@@ -149,7 +150,7 @@ public class CaptureScreen extends Threa
                }
        }
        */
-       
+
        public void pushVideo(VideoData data, int ts) throws IOException {
                if (startPublish) {
                        if (Red5.getConnectionLocal() == null) {
@@ -188,7 +189,7 @@ public class CaptureScreen extends Threa
                return se;
        }
 
-       public ArrayBlockingQueue<VideoData> getFrames() {
+       public Queue<VideoData> getFrames() {
                return frames;
        }
 

Modified: 
openmeetings/application/trunk/openmeetings-screenshare/src/main/java/org/apache/openmeetings/screenshare/Core.java
URL: 
http://svn.apache.org/viewvc/openmeetings/application/trunk/openmeetings-screenshare/src/main/java/org/apache/openmeetings/screenshare/Core.java?rev=1784854&r1=1784853&r2=1784854&view=diff
==============================================================================
--- 
openmeetings/application/trunk/openmeetings-screenshare/src/main/java/org/apache/openmeetings/screenshare/Core.java
 (original)
+++ 
openmeetings/application/trunk/openmeetings-screenshare/src/main/java/org/apache/openmeetings/screenshare/Core.java
 Wed Mar  1 06:11:13 2017
@@ -76,7 +76,7 @@ public class Core implements IPendingSer
        private String host;
        private String app;
        private int port;
-       
+
        public String publishName;
        private CaptureScreen _capture = null;
        private RTMPClientPublish publishClient = null;
@@ -219,7 +219,7 @@ public class Core implements IPendingSer
                        int x = (int)(Ampl_factor * (mouseP.getX() - spinnerX) 
* scaleFactor);
                        int y = (int)(Ampl_factor * (mouseP.getY() - spinnerY) 
* scaleFactor);
 
-                       Map<String, Object> cursorPosition = new 
HashMap<String, Object>();
+                       Map<String, Object> cursorPosition = new HashMap<>();
                        cursorPosition.put("publicSID", publishName);
                        cursorPosition.put("cursor_x", x);
                        cursorPosition.put("cursor_y", y);
@@ -247,7 +247,7 @@ public class Core implements IPendingSer
                        if (Red5.getConnectionLocal() == null) {
                                
Red5.setConnectionLocal(instance.getConnection());
                        }
-                       Map<String, Object> map = new HashMap<String, Object>();
+                       Map<String, Object> map = new HashMap<>();
                        map.put("screenX", spinnerX);
                        map.put("screenY", spinnerY);
 
@@ -282,28 +282,28 @@ public class Core implements IPendingSer
                startSharing = true;
                captureScreenStart();
        }
-       
+
        public void recordingStart() {
                startRecording= true;
                captureScreenStart();
        }
-       
+
        public void publishingStart() {
                startPublishing = true;
                captureScreenStart();
        }
-       
+
        private void connect(String parentSid) {
                Map<String, Object> map = 
instance.makeDefaultConnectionParams(host, port, app);
                map.put("screenClient", true);
                map.put("parentSid", parentSid);
                instance.connect(host, port, map, this);
        }
-       
+
        private void captureScreenStart() {
                try {
                        log.debug("captureScreenStart");
-                       
+
                        if (!isConnected) {
                                connect(publishName);
                        } else {
@@ -324,22 +324,22 @@ public class Core implements IPendingSer
                startSharing = false;
                captureScreenStop("stopStreaming");
        }
-       
+
        public void recordingStop() {
                startRecording = false;
                captureScreenStop("stopRecording");
        }
-       
+
        public void publishingStop() {
                startPublishing = false;
                captureScreenStop("stopPublishing");
        }
-       
+
        private void captureScreenStop(String action) {
                try {
                        log.debug("INVOKE screenSharerAction" );
 
-                       Map<String, Object> map = new HashMap<String, Object>();
+                       Map<String, Object> map = new HashMap<>();
                        map.put(action, true);
 
                        if (Red5.getConnectionLocal() == null) {
@@ -361,12 +361,12 @@ public class Core implements IPendingSer
                frame.setSharingStatus(false, !startPublishing && 
!startRecording && !startSharing);
                startSharing = false;
        }
-       
+
        public void stopRecording() {
                frame.setRecordingStatus(false, !startPublishing && 
!startRecording && !startSharing);
                startRecording = false;
        }
-       
+
        public void stopPublishing() {
                frame.setPublishingStatus(false, !startPublishing && 
!startRecording && !startSharing);
                startPublishing = false;
@@ -375,15 +375,15 @@ public class Core implements IPendingSer
                        publishClient = null;
                }
        }
-       
+
        synchronized public boolean isReadyToRecord() {
                return readyToRecord;
        }
-       
+
        synchronized private void setReadyToRecord(boolean readyToRecord) {
                this.readyToRecord = readyToRecord;
        }
-       
+
        protected void onCommand(RTMPConnection conn, Channel channel, Header 
source, ICommand command) {
                if (!(command instanceof Notify)) {
                        return;
@@ -392,7 +392,7 @@ public class Core implements IPendingSer
                if (invoke.getType() == IEvent.Type.STREAM_DATA) {
                        return;
                }
-               
+
                String method = invoke.getCall().getServiceMethodName();
                if ("screenSharerAction".equals(method)) {
                        Object[] args = invoke.getCall().getArguments();
@@ -446,7 +446,7 @@ public class Core implements IPendingSer
        private static boolean bool(Object b) {
                return TRUE.equals(Boolean.valueOf("" + b));
        }
-       
+
        public void sendRemoteCursorEvent(Map<String, Object> obj) {
                if (!remoteEnabled) {
                        return;
@@ -475,7 +475,7 @@ public class Core implements IPendingSer
                                log.trace("" + o);
                        }
                        @SuppressWarnings("unchecked")
-                       Map<String, Object> returnMap = (o != null && o 
instanceof Map) ? (Map<String, Object>) o : new HashMap<String, Object>();
+                       Map<String, Object> returnMap = (o != null && o 
instanceof Map) ? (Map<String, Object>) o : new HashMap<>();
                        log.trace("call ### get Method Name " + method);
                        if ("connect".equals(method)) {
                                Object code = returnMap.get("code");
@@ -520,9 +520,9 @@ public class Core implements IPendingSer
                                        }
                                        log.debug("createPublishStream result 
stream id: {}; name: {}", getCapture().getStreamId(), publishName);
                                        
instance.publish(getCapture().getStreamId(), publishName, "live", this);
-       
+
                                        log.debug("setup capture thread 
spinnerWidth = {}; spinnerHeight = {};", spinnerWidth, spinnerHeight);
-       
+
                                        if (!getCapture().isAlive()) {
                                                
getCapture().setSendCursor(startSharing);
                                                getCapture().start();
@@ -566,7 +566,7 @@ public class Core implements IPendingSer
        public void setRemoteEnabled(boolean remoteEnabled) {
                this.remoteEnabled = remoteEnabled;
        }
-       
+
        public void setDeadlockGuard(RTMPConnection conn) {
                ThreadPoolTaskScheduler deadlockGuard = new 
ThreadPoolTaskScheduler();
                deadlockGuard.setPoolSize(16);


Reply via email to