コード例 #1
0
 public static boolean isNonRenderer(InetAddress socket) {
   Device d = getDevice(socket);
   boolean b = (d != null && !isMediaRenderer(d));
   if (b) {
     LOGGER.debug("Device at {} is {}: {}", socket, d.getType(), d.toString());
   }
   return b;
 }
コード例 #2
0
 public static boolean isMediaRenderer(Device d) {
   String t = d.getType().getType();
   for (DeviceType r : mediaRendererTypes) {
     if (r.getType().equals(t)) {
       return true;
     }
   }
   return false;
 }
コード例 #3
0
 protected synchronized boolean addRenderer(Device d) {
   if (d != null) {
     String uuid = getUUID(d);
     if (isMediaRenderer(d) && rendererFound(d, uuid) != null) {
       LOGGER.debug("Adding device: {} {}", d.getType(), d.toString());
       rendererMap.mark(uuid, ACTIVE, true);
       subscribeAll(d, uuid);
       rendererReady(uuid);
       return true;
     }
   }
   return false;
 }