diff options
Diffstat (limited to 'discovery/org.eclipse.tm.discovery.doc.isv/guide/usage.html')
-rw-r--r-- | discovery/org.eclipse.tm.discovery.doc.isv/guide/usage.html | 46 |
1 files changed, 0 insertions, 46 deletions
diff --git a/discovery/org.eclipse.tm.discovery.doc.isv/guide/usage.html b/discovery/org.eclipse.tm.discovery.doc.isv/guide/usage.html deleted file mode 100644 index ac381cf98..000000000 --- a/discovery/org.eclipse.tm.discovery.doc.isv/guide/usage.html +++ /dev/null @@ -1,46 +0,0 @@ -<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN"> -<html> -<head> -<meta name="copyright" content="Copyright (c) Symbian Software Ltd 2007. This page is made available under license. For full details see the LEGAL in the documentation book that contains this page." > -<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"> -<meta http-equiv="Content-Style-Type" content="text/css"> -<link rel="stylesheet" href="../book.css" charset="ISO-8859-1" type="text/css"> -<title>Programmatic usage</title> -</head> -<body> -<h1>Programmatic usage</h1> -<p> -Perform service discovery session: -</p> -<pre> -<samp> -int timeout = 500; // milliseconds -String query = "_services._dns-sd._udp.local."; //DNS-SD query - -//instantiate protocol by name attribute -IProtocol protocol = ProtocolFactory.getProtocol("DNS-SD"); - -//instantiate transport by name attribute -ITransport transport = TransportFactory.getTransport("UDP", "224.0.0.251", timeout); - -//get engine instance and kick off discovery -ServiceDiscoveryEngine serviceDiscoveryEngine = ServiceDiscoveryEngine.getInstance(); -serviceDiscoveryEngine.doServiceDiscovery(query, protocol,transport); -</samp> -</pre> -<p> -Access EMF model: -</p> -<pre> -<samp> -//get engine instance -ServiceDiscoveryEngine serviceDiscoveryEngine = ServiceDiscoveryEngine.getInstance(); - -//access org.eclipse.emf.ecore.resource.Resource -Resource model = serviceDiscoveryEngine.getResource(); -</samp> -</pre> - - -</body> -</html>
\ No newline at end of file |