Examples of associateIP()


Examples of net.pms.configuration.RendererConfiguration.associateIP()

        // Attempt 2: try to recognize the renderer by matching headers
        renderer = RendererConfiguration.getRendererConfigurationByHeaders(sortedHeaders);
      }

      if (renderer != null) {
        renderer.associateIP(ia);
        PMS.get().setRendererFound(renderer);
      }

      for (String headerLine : headerLines) {
        LOGGER.trace("Received on socket: " + headerLine);
View Full Code Here

Examples of net.pms.configuration.RendererConfiguration.associateIP()

      // Attempt 2: try to recognize the renderer by matching headers
      renderer = RendererConfiguration.getRendererConfigurationByHeaders(headers.entries());
    }

    if (renderer != null) {
      renderer.associateIP(ia);
      PMS.get().setRendererFound(renderer);
      request.setMediaRenderer(renderer);
    }

    Set<String> headerNames = headers.names();
View Full Code Here

Examples of net.pms.configuration.RendererConfiguration.associateIP()

        // Attempt 2: try to recognize the renderer by matching the "User-Agent" header
        renderer = RendererConfiguration.getRendererConfigurationByUA(userAgentString);

        if (renderer != null) {
          request.setMediaRenderer(renderer);
          renderer.associateIP(ia)// Associate IP address for later requests
          PMS.get().setRendererFound(renderer);
          logger.trace("Matched media renderer \"" + renderer.getRendererName() + "\" based on header \"" + headerLine + "\"");
        }
      }
View Full Code Here

Examples of net.pms.configuration.RendererConfiguration.associateIP()

        // Attempt 3: try to recognize the renderer by matching an additional header
        renderer = RendererConfiguration.getRendererConfigurationByUAAHH(headerLine);

        if (renderer != null) {
          request.setMediaRenderer(renderer);
          renderer.associateIP(ia)// Associate IP address for later requests
          PMS.get().setRendererFound(renderer);
          logger.trace("Matched media renderer \"" + renderer.getRendererName() + "\" based on header \"" + headerLine + "\"");
        }
      }
View Full Code Here

Examples of net.pms.configuration.RendererConfiguration.associateIP()

          renderer = RendererConfiguration.getRendererConfigurationByUA(userAgentString);

          if (renderer != null) {
            PMS.get().setRendererFound(renderer);
            request.setMediaRenderer(renderer);
            renderer.associateIP(ia)// Associate IP address for later requests
            logger.trace("Matched media renderer \"" + renderer.getRendererName() + "\" based on header \"" + headerLine + "\"");
          }
        }
        if (renderer == null && headerLine != null && request != null) {
          // Attempt 3: try to recognize the renderer by matching an additional header
View Full Code Here

Examples of net.pms.configuration.RendererConfiguration.associateIP()

          renderer = RendererConfiguration.getRendererConfigurationByUAAHH(headerLine);

          if (renderer != null) {
            PMS.get().setRendererFound(renderer);
            request.setMediaRenderer(renderer);
            renderer.associateIP(ia)// Associate IP address for later requests
            logger.trace("Matched media renderer \"" + renderer.getRendererName() + "\" based on header \"" + headerLine + "\"");
          }
        }
        try {
          StringTokenizer s = new StringTokenizer(headerLine);
View Full Code Here

Examples of net.pms.configuration.WebRender.associateIP()

    tag.add("web");
    root = new RootFolder(tag);
    try {
      WebRender render = new WebRender(name);
      root.setDefaultRenderer(render);
      render.associateIP(t.getRemoteAddress().getAddress());
      render.associatePort(t.getRemoteAddress().getPort());
      render.setUA(t.getRequestHeaders().getFirst("User-agent"));
      PMS.get().setRendererFound(render);
    } catch (ConfigurationException e) {
      root.setDefaultRenderer(RendererConfiguration.getDefaultConf());
View Full Code Here

Examples of net.pms.configuration.WebRender.associateIP()

    return root;
  }

  public void associate(HttpExchange t, RendererConfiguration r) {
    WebRender wr = (WebRender) r;
    wr.associateIP(t.getRemoteAddress().getAddress());
    wr.associatePort(t.getRemoteAddress().getPort());
  }

  private void addCtx(String path, HttpHandler h) {
    HttpContext ctx = server.createContext(path, h);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.