Home TOC |
![]() ![]() ![]() |
Using the JAXR API to Access the Registry Server
You can access the Registry Server by using the sample programs in the
docs/tutorial/examples/jaxr
directory (on UNIX systems) or thedocs\tutorial\examples\jaxr
directory (on Microsoft Windows systems). You need to edit them as followsIn
JAXRPublish.java
andJAXRDelete.java
, for both thequeryURL
and thepublishURL
, specify the Registry Server by using the following string (on one line):"http://hostname
:8080/registry-server/RegistryServerServlet";where
hostname
is the fully qualified host name. Do not usehttps:
for thepublishURL
.Edit the lines that specify a username and password by providing any non-empty string. For example:
// Edit to provide your own username and password String username = "x"; String password = "y";In
JAXRQuery.java
, specify the Registry Server as follows:props.setProperty("javax.xml.registry.queryManagerURL", "http://hostname
:8080/registry-server/RegistryServerServlet");Also in
JAXRQuery.java
, remove the percent (%
) signs from the following line:namePatterns.add("%" + qString + "%");Instead, specify the
namePatterns
for the query string as follows:namePatterns.add(qString);
Home TOC |
![]() ![]() ![]() |