Package javax.jmdns.impl

Examples of javax.jmdns.impl.ServiceInfoImpl$ServiceInfoState


                logger.finer("run() JmDNS canceling service");
                // announce the service
                //long now = System.currentTimeMillis();
                DNSOutgoing out = new DNSOutgoing(DNSConstants.FLAGS_QR_RESPONSE | DNSConstants.FLAGS_AA);
                for (int i = 0; i < infos.length; i++) {
                    ServiceInfoImpl info = infos[i];
                    info.addAnswers(out, ttl, this.jmDNSImpl.getLocalHost());

                    this.jmDNSImpl.getLocalHost().addAddressRecords(out, false);
                }
                this.jmDNSImpl.send(out);
            } else {
View Full Code Here


                    logger.finer("run() JmDNS querying service");
                    long now = System.currentTimeMillis();
                    DNSOutgoing out = new DNSOutgoing(DNSConstants.FLAGS_QR_QUERY);
                    out.addQuestion(new DNSQuestion(type, DNSConstants.TYPE_PTR, DNSConstants.CLASS_IN));
                    for (Iterator s = this.jmDNSImpl.getServices().values().iterator(); s.hasNext();) {
                        final ServiceInfoImpl info = (ServiceInfoImpl) s.next();
                        try {
                            out.addAnswer(new DNSRecord.Pointer(info.getType(), DNSConstants.TYPE_PTR, DNSConstants.CLASS_IN, DNSConstants.DNS_TTL, info.getQualifiedName()), now);
                        } catch (IOException ee) {
                            break;
                        }
                    }
                    this.jmDNSImpl.send(out);
View Full Code Here

     * @param priority priority of the service
     * @param text     string describing the service
     */
    public static ServiceInfo create(String type, String name, int port, int weight, int priority, String text)
    {
        return new ServiceInfoImpl(type, name, port, weight, priority, text);
    }
View Full Code Here

     * @param priority priority of the service
     * @param props    properties describing the service
     */
    public static ServiceInfo create(String type, String name, int port, int weight, int priority, Hashtable props)
    {
        return new ServiceInfoImpl(type, name, port, weight, priority, props);
    }
View Full Code Here

     * @param priority priority of the service
     * @param text     bytes describing the service
     */
    public static ServiceInfo create(String type, String name, int port, int weight, int priority, byte text[])
    {
        return new ServiceInfoImpl(type, name, port, weight, priority, text);
    }
View Full Code Here

     * @param port the local port on which the service runs
     * @param text string describing the service
     */
    public static ServiceInfo create(String type, String name, int port, String text)
    {
        return new ServiceInfoImpl(type, name, port, text);
    }
View Full Code Here

     * @param priority priority of the service
     * @param text     string describing the service
     */
    public static ServiceInfo create(String type, String name, int port, int weight, int priority, String text)
    {
        return new ServiceInfoImpl(type, name, port, weight, priority, text);
    }
View Full Code Here

     * @param priority priority of the service
     * @param props    properties describing the service
     */
    public static ServiceInfo create(String type, String name, int port, int weight, int priority, Hashtable props)
    {
        return new ServiceInfoImpl(type, name, port, weight, priority, props);
    }
View Full Code Here

     * @param priority priority of the service
     * @param text     bytes describing the service
     */
    public static ServiceInfo create(String type, String name, int port, int weight, int priority, byte text[])
    {
        return new ServiceInfoImpl(type, name, port, weight, priority, text);
    }
View Full Code Here

        // Associate services to this, if they need announcing
        synchronized (this.jmDNSImpl)
        {
            for (Iterator s = this.jmDNSImpl.getServices().values().iterator(); s.hasNext();)
            {
                ServiceInfoImpl info = (ServiceInfoImpl) s.next();
                if (info.getState() == DNSState.ANNOUNCING_1)
                {
                    info.setTask(this);
                }
            }
        }
    }
View Full Code Here

TOP

Related Classes of javax.jmdns.impl.ServiceInfoImpl$ServiceInfoState

Copyright © 2018 www.massapicom. 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.