http://git-wip-us.apache.org/repos/asf/juddi/blob/06b2a02d/jacoco/juddi-client/jacoco-ut/org.apache.juddi.v3.client.config/ClientConfig.java.html ---------------------------------------------------------------------- diff --git a/jacoco/juddi-client/jacoco-ut/org.apache.juddi.v3.client.config/ClientConfig.java.html b/jacoco/juddi-client/jacoco-ut/org.apache.juddi.v3.client.config/ClientConfig.java.html new file mode 100644 index 0000000..4be1b97 --- /dev/null +++ b/jacoco/juddi-client/jacoco-ut/org.apache.juddi.v3.client.config/ClientConfig.java.html @@ -0,0 +1,866 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="en"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>ClientConfig.java</title><link rel="stylesheet" href="../jacoco-resources/prettify.css" type="text/css"/><script type="text/javascript" src="../jacoco-resources/prettify.js"></script></head><body onload="window['PR_TAB_WIDTH']=4;prettyPrint()"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">jUDDI Client side Code</a> > <a href="index.source.html" class="el_package">org.apache.juddi.v3.client.config</a> > <span class="el_so urce">ClientConfig.java</span></div><h1>ClientConfig.java</h1><pre class="source lang-java linenums">/* + * Copyright 2001-2009 The Apache Software Foundation. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ +package org.apache.juddi.v3.client.config; + +import java.io.File; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.HashSet; +import java.util.Iterator; +import java.util.List; +import java.util.Map; +import java.util.Properties; +import java.util.Set; + +import javax.xml.crypto.dsig.CanonicalizationMethod; + +import org.apache.commons.configuration.CompositeConfiguration; +import org.apache.commons.configuration.Configuration; +import org.apache.commons.configuration.ConfigurationException; +import org.apache.commons.configuration.SystemConfiguration; +import org.apache.commons.configuration.XMLConfiguration; +import org.apache.commons.configuration.reloading.FileChangedReloadingStrategy; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.juddi.api_v3.Node; +import org.apache.juddi.v3.client.cryptor.CryptorFactory; +import org.apache.juddi.v3.client.cryptor.DigSigUtil; +import org.apache.juddi.v3.client.subscription.SubscriptionCallbackListener; + +/** + * Handles the client configuration of the uddi-client. By default it first + * looks at system properties. Then loads from the config file from the system + * property "uddi.client.xml", next the user specified file, finally, + * "META-INF/uddi.xml" + * + * @author <a href="mailto:[email protected]">Kurt T Stam</a> + * @author <a href="mailto:[email protected]">Alex O'Ree</a> + */ +public class ClientConfig { + + public final static String UDDI_CONFIG_FILENAME_PROPERTY = "uddi.client.xml"; + public final static String DEFAULT_UDDI_CONFIG = "META-INF/uddi.xml"; +<span class="fc" id="L57"> private Log log = LogFactory.getLog(ClientConfig.class);</span> +<span class="fc" id="L58"> private Configuration config = null;</span> + +<span class="fc" id="L60"> private Map<String, UDDINode> uddiNodes = null;</span> +<span class="fc" id="L61"> private Map<String, UDDIClerk> uddiClerks = null;</span> +<span class="fc" id="L62"> private Set<XRegistration> xBusinessRegistrations = null;</span> +<span class="fc" id="L63"> private Set<XRegistration> xServiceBindingRegistrations = null;</span> +<span class="fc" id="L64"> private String clientName = null;</span> +<span class="fc" id="L65"> private String clientCallbackUrl = null;</span> +<span class="fc" id="L66"> private String configurationFile = null;</span> + + /** + * Constructor (note Singleton pattern). + * + * @throws ConfigurationException + */ +<span class="fc" id="L73"> public ClientConfig(String configurationFile) throws ConfigurationException {</span> +<span class="fc" id="L74"> loadConfiguration(configurationFile, null);</span> +<span class="fc" id="L75"> }</span> + + /** + * Constructor (note Singleton pattern). + * + * @throws ConfigurationException + */ +<span class="fc" id="L82"> public ClientConfig(String configurationFile, Properties properties) throws ConfigurationException {</span> +<span class="fc" id="L83"> loadConfiguration(configurationFile, properties);</span> +<span class="fc" id="L84"> }</span> + + /** + * Attempts to save any changes made to the configuration back to disk + * Revised in 3.2.1 to reconstruct the file from the in memory data + * structure, enable you to programmatically add nodes. + * <br><br> + * For previous functionality see, saveConfigRaw() + * + * @throws ConfigurationException + */ + public void saveConfig() throws ConfigurationException { + +<span class="pc bpc" id="L97" title="1 of 2 branches missed."> if (log.isDebugEnabled()) {</span> +<span class="nc" id="L98"> System.out.println("DEBUG dumping current cfg");</span> +<span class="nc" id="L99"> Iterator<String> keys = config.getKeys();</span> +<span class="nc bnc" id="L100" title="All 2 branches missed."> while (keys.hasNext()) {</span> +<span class="nc" id="L101"> String k = keys.next();</span> +<span class="nc" id="L102"> System.out.println(k + " = " + config.getProperty(k));</span> +<span class="nc" id="L103"> }</span> + } +<span class="fc" id="L105"> XMLConfiguration saveConfiguration = new XMLConfiguration();</span> +<span class="fc" id="L106"> Configuration cc = new CompositeConfiguration(saveConfiguration);</span> + +<span class="fc" id="L108"> saveConfiguration.setRootElementName("uddi");</span> + + +<span class="fc" id="L111"> cc.addProperty("client(0).selection.policy", config.getProperty("client.selection.policy"));</span> +<span class="fc" id="L112"> cc.addProperty("reloadDelay", config.getProperty("reloadDelay"));</span> +<span class="fc" id="L113"> addCurrentNodeConfig(cc);</span> +<span class="fc" id="L114"> addCurrentClerks(cc);</span> + try { +<span class="fc" id="L116"> addDigitalSubscription(cc);</span> +<span class="nc" id="L117"> } catch (Exception ex) {</span> +<span class="nc" id="L118"> throw new ConfigurationException("error", ex);</span> +<span class="fc" id="L119"> }</span> +<span class="fc" id="L120"> addSubscriptionCallback(cc);</span> +<span class="fc" id="L121"> addXRegistration(cc);</span> +<span class="pc bpc" id="L122" title="1 of 2 branches missed."> if (log.isDebugEnabled()) {</span> +<span class="nc" id="L123"> System.out.println("DEBUG dumping NEW cfg");</span> +<span class="nc" id="L124"> Iterator<String> keys = cc.getKeys();</span> + +<span class="nc bnc" id="L126" title="All 2 branches missed."> while (keys.hasNext()) {</span> +<span class="nc" id="L127"> String k = keys.next();</span> +<span class="nc" id="L128"> System.out.println(k + " = " + config.getProperty(k));</span> +<span class="nc" id="L129"> }</span> + } + +<span class="fc" id="L132"> saveConfiguration.save(configurationFile);</span> +<span class="fc" id="L133"> }</span> + + /** + * Use this method to attempt to save the jUDDI configuration file after + * you've modified it using the Apache Commons Configuration settings. + * This is especially useful if you've constructed a user interface for manipulating + * the configuration like a properties sheet and is used by the juddi-gui (web ui) + * @since 3.2.1 + * @throws org.apache.commons.configuration.ConfigurationException + */ + public void saveConfigRaw() throws ConfigurationException{ +<span class="nc" id="L144"> XMLConfiguration saveConfiguration = new XMLConfiguration(configurationFile);</span> +<span class="nc" id="L145"> Configuration cc = new CompositeConfiguration(saveConfiguration);</span> +<span class="nc" id="L146"> Iterator<String> keys = this.config.getKeys();</span> +<span class="nc bnc" id="L147" title="All 2 branches missed."> while (keys.hasNext()){</span> +<span class="nc" id="L148"> String key = keys.next();</span> +<span class="nc bnc" id="L149" title="All 4 branches missed."> if (key.startsWith("client") || key.startsWith("config"))</span> + { +<span class="nc" id="L151"> cc.setProperty(key, config.getProperty(key));</span> + } +<span class="nc" id="L153"> }</span> +<span class="nc" id="L154"> saveConfiguration.save();</span> + +<span class="nc" id="L156"> }</span> + protected void readConfig(Properties properties) throws ConfigurationException { +<span class="fc" id="L158"> uddiNodes = readNodeConfig(config, properties);</span> +<span class="fc" id="L159"> uddiClerks = readClerkConfig(config, uddiNodes);</span> +<span class="fc" id="L160"> xServiceBindingRegistrations = readXServiceBindingRegConfig(config, uddiClerks);</span> +<span class="fc" id="L161"> xBusinessRegistrations = readXBusinessRegConfig(config, uddiClerks);</span> +<span class="fc" id="L162"> }</span> + + /** + * Does the actual work of reading the configuration from System + * Properties and/or uddi.xml file. When the uddi.xml file is updated + * the file will be reloaded. By default the reloadDelay is set to 1 + * second to prevent excessive date stamp checking. + */ + private void loadConfiguration(String configurationFile, Properties properties) throws ConfigurationException { + //Properties from system properties +<span class="fc" id="L172"> CompositeConfiguration compositeConfig = new CompositeConfiguration();</span> +<span class="fc" id="L173"> compositeConfig.addConfiguration(new SystemConfiguration());</span> + //Properties from XML file +<span class="pc bpc" id="L175" title="1 of 2 branches missed."> if (System.getProperty(UDDI_CONFIG_FILENAME_PROPERTY) != null) {</span> +<span class="nc" id="L176"> log.info("Using system property config override");</span> +<span class="nc" id="L177"> configurationFile = System.getProperty(UDDI_CONFIG_FILENAME_PROPERTY);</span> + } +<span class="fc" id="L179"> XMLConfiguration xmlConfig = null;</span> +<span class="fc bfc" id="L180" title="All 2 branches covered."> if (configurationFile != null) {</span> +<span class="fc" id="L181"> xmlConfig = new XMLConfiguration(configurationFile);</span> + } else { +<span class="fc" id="L183"> final String filename = System.getProperty(UDDI_CONFIG_FILENAME_PROPERTY);</span> +<span class="pc bpc" id="L184" title="1 of 2 branches missed."> if (filename != null) {</span> +<span class="nc" id="L185"> xmlConfig = new XMLConfiguration(filename);</span> + } else { +<span class="fc" id="L187"> xmlConfig = new XMLConfiguration(DEFAULT_UDDI_CONFIG);</span> + } + } +<span class="fc" id="L190"> log.info("Reading UDDI Client properties file " + xmlConfig.getBasePath() + " use -D" + UDDI_CONFIG_FILENAME_PROPERTY + " to override");</span> +<span class="fc" id="L191"> this.configurationFile = xmlConfig.getBasePath();</span> +<span class="fc" id="L192"> long refreshDelay = xmlConfig.getLong(Property.UDDI_RELOAD_DELAY, 1000l);</span> +<span class="fc" id="L193"> log.debug("Setting refreshDelay to " + refreshDelay);</span> +<span class="fc" id="L194"> FileChangedReloadingStrategy fileChangedReloadingStrategy = new FileChangedReloadingStrategy();</span> +<span class="fc" id="L195"> fileChangedReloadingStrategy.setRefreshDelay(refreshDelay);</span> +<span class="fc" id="L196"> xmlConfig.setReloadingStrategy(fileChangedReloadingStrategy);</span> +<span class="fc" id="L197"> compositeConfig.addConfiguration(xmlConfig);</span> + //Making the new configuration globally accessible. +<span class="fc" id="L199"> config = compositeConfig;</span> +<span class="fc" id="L200"> readConfig(properties);</span> + +<span class="fc" id="L202"> validateConfig();</span> +<span class="fc" id="L203"> }</span> + + private Map<String, UDDIClerk> readClerkConfig(Configuration config, Map<String, UDDINode> uddiNodes) + throws ConfigurationException { +<span class="fc" id="L207"> clientName = config.getString("client[@name]");</span> +<span class="fc" id="L208"> clientCallbackUrl = config.getString("client[@callbackUrl]");</span> +<span class="fc" id="L209"> Map<String, UDDIClerk> clerks = new HashMap<String, UDDIClerk>();</span> +<span class="pc bpc" id="L210" title="1 of 2 branches missed."> if (config.containsKey("client.clerks.clerk[@name]")) {</span> +<span class="fc" id="L211"> String[] names = config.getStringArray("client.clerks.clerk[@name]");</span> + +<span class="fc" id="L213"> log.debug("clerk names=" + names.length);</span> +<span class="fc bfc" id="L214" title="All 2 branches covered."> for (int i = 0; i < names.length; i++) {</span> +<span class="fc" id="L215"> UDDIClerk uddiClerk = new UDDIClerk();</span> +<span class="fc" id="L216"> uddiClerk.setManagerName(clientName);</span> +<span class="fc" id="L217"> uddiClerk.setName(config.getString("client.clerks.clerk(" + i + ")[@name]"));</span> +<span class="fc" id="L218"> String nodeRef = config.getString("client.clerks.clerk(" + i + ")[@node]");</span> +<span class="pc bpc" id="L219" title="1 of 2 branches missed."> if (!uddiNodes.containsKey(nodeRef)) {</span> +<span class="nc" id="L220"> throw new ConfigurationException("Could not find Node with name=" + nodeRef);</span> + } +<span class="fc" id="L222"> UDDINode uddiNode = uddiNodes.get(nodeRef);</span> +<span class="fc" id="L223"> uddiClerk.setUDDINode(uddiNode);</span> +<span class="fc" id="L224"> uddiClerk.setPublisher(config.getString("client.clerks.clerk(" + i + ")[@publisher]"));</span> +<span class="fc" id="L225"> uddiClerk.setPassword(config.getString("client.clerks.clerk(" + i + ")[@password]"));</span> +<span class="fc" id="L226"> uddiClerk.setIsPasswordEncrypted(config.getBoolean("client.clerks.clerk(" + i + ")[@isPasswordEncrypted]", false));</span> +<span class="fc" id="L227"> uddiClerk.setCryptoProvider(config.getString("client.clerks.clerk(" + i + ")[@cryptoProvider]"));</span> + +<span class="fc" id="L229"> String clerkBusinessKey = config.getString("client.clerks.clerk(" + i + ")[@businessKey]");</span> +<span class="fc" id="L230"> String clerkBusinessName = config.getString("client.clerks.clerk(" + i + ")[@businessName]");</span> +<span class="fc" id="L231"> String clerkKeyDomain = config.getString("client.clerks.clerk(" + i + ")[@keyDomain]");</span> + +<span class="fc" id="L233"> String[] classes = config.getStringArray("client.clerks.clerk(" + i + ").class");</span> +<span class="fc" id="L234"> uddiClerk.setClassWithAnnotations(classes);</span> + +<span class="fc" id="L236"> int numberOfWslds = config.getStringArray("client.clerks.clerk(" + i + ").wsdl").length;</span> +<span class="fc bfc" id="L237" title="All 2 branches covered."> if (numberOfWslds > 0) {</span> +<span class="fc" id="L238"> UDDIClerk.WSDL[] wsdls = new UDDIClerk.WSDL[numberOfWslds];</span> +<span class="fc bfc" id="L239" title="All 2 branches covered."> for (int w = 0; w < wsdls.length; w++) {</span> + +<span class="fc" id="L241"> UDDIClerk.WSDL wsdl = new UDDIClerk.WSDL();</span> +<span class="fc" id="L242"> String fileName = config.getString("client.clerks.clerk(" + i + ").wsdl(" + w + ")");</span> +<span class="fc" id="L243"> wsdl.setFileName(fileName);</span> +<span class="pc bpc" id="L244" title="1 of 2 branches missed."> if (!new File(fileName).exists()) {</span> +<span class="fc" id="L245"> log.warn("The wsdl file referenced in the config at '" + fileName + "' doesn't exist!");</span> + } +<span class="fc" id="L247"> String businessKey = config.getString("client.clerks.clerk(" + i + ").wsdl(" + w + ")[@businessKey]");</span> +<span class="fc" id="L248"> String businessName = config.getString("client.clerks.clerk(" + i + ").wsdl(" + w + ")[@businessName]");</span> +<span class="fc" id="L249"> String keyDomain = config.getString("client.clerks.clerk(" + i + ").wsdl(" + w + ")[@keyDomain]");</span> +<span class="pc bpc" id="L250" title="1 of 2 branches missed."> if (businessKey == null) {</span> +<span class="nc" id="L251"> businessKey = clerkBusinessKey;</span> + } +<span class="pc bpc" id="L253" title="1 of 2 branches missed."> if (businessKey == null) {</span> +<span class="nc" id="L254"> businessKey = uddiClerk.getUDDINode().getProperties().getProperty("businessKey");</span> + } +<span class="pc bpc" id="L256" title="1 of 2 branches missed."> if (businessKey == null) {</span> + //use key convention to build the businessKey +<span class="nc bnc" id="L258" title="All 2 branches missed."> if (businessName == null) {</span> +<span class="nc" id="L259"> businessName = clerkBusinessName;</span> + } +<span class="nc bnc" id="L261" title="All 2 branches missed."> if (keyDomain == null) {</span> +<span class="nc" id="L262"> keyDomain = clerkKeyDomain;</span> + } +<span class="nc bnc" id="L264" title="All 2 branches missed."> if (keyDomain == null) {</span> +<span class="nc" id="L265"> keyDomain = uddiClerk.getUDDINode().getProperties().getProperty("keyDomain");</span> + } +<span class="nc bnc" id="L267" title="All 6 branches missed."> if ((businessName == null && !uddiClerk.getUDDINode().getProperties().containsKey("businessName"))</span> +<span class="nc bnc" id="L268" title="All 2 branches missed."> || keyDomain == null && !uddiClerk.getUDDINode().getProperties().containsKey("keyDomain")) {</span> +<span class="nc" id="L269"> throw new ConfigurationException("Either the wsdl(" + wsdls[w]</span> + + ") or clerk (" + uddiClerk.name + ") elements require a businessKey, or businessName & keyDomain attributes"); + } else { +<span class="nc" id="L272"> Properties properties = new Properties(uddiClerk.getUDDINode().getProperties());</span> +<span class="nc bnc" id="L273" title="All 2 branches missed."> if (businessName != null) {</span> +<span class="nc" id="L274"> properties.put("businessName", businessName);</span> + } +<span class="nc bnc" id="L276" title="All 2 branches missed."> if (keyDomain != null) {</span> +<span class="nc" id="L277"> properties.put("keyDomain", keyDomain);</span> + } +<span class="nc" id="L279"> businessKey = UDDIKeyConvention.getBusinessKey(properties);</span> + } + } +<span class="pc bpc" id="L282" title="2 of 4 branches missed."> if (!businessKey.toLowerCase().startsWith("uddi:") || !businessKey.substring(5).contains(":")) {</span> +<span class="nc" id="L283"> throw new ConfigurationException("The businessKey '" + businessKey + "' does not implement a valid UDDI v3 key format. See config file at client.clerks.clerk(" + i + ").wsdl(" + w + ")[@businessKey]");</span> + } +<span class="fc" id="L285"> wsdl.setBusinessKey(businessKey);</span> +<span class="pc bpc" id="L286" title="1 of 2 branches missed."> if (keyDomain == null) {</span> +<span class="nc" id="L287"> keyDomain = businessKey.split(":")[1];</span> + } +<span class="fc" id="L289"> wsdl.setKeyDomain(keyDomain);</span> +<span class="fc" id="L290"> wsdls[w] = wsdl;</span> + } +<span class="fc" id="L292"> uddiClerk.setWsdls(wsdls);</span> + } + +<span class="fc" id="L295"> clerks.put(names[i], uddiClerk);</span> + } + } +<span class="fc" id="L298"> return clerks;</span> + } + + /** + * signals that the specified classes/wsdls are registered with the UDDI + * server when UDDIClient.start() is called + * client.clerks[@registerOnStartup] + * + * @return true/false + */ + public boolean isRegisterOnStartup() { +<span class="fc" id="L309"> boolean isRegisterOnStartup = false;</span> +<span class="pc bpc" id="L310" title="1 of 2 branches missed."> if (config.containsKey("client.clerks[@registerOnStartup]")) {</span> +<span class="fc" id="L311"> isRegisterOnStartup = config.getBoolean("client.clerks[@registerOnStartup]");</span> + } +<span class="fc" id="L313"> return isRegisterOnStartup;</span> + } + + private Map<String, UDDINode> readNodeConfig(Configuration config, Properties properties) + throws ConfigurationException { +<span class="fc" id="L318"> String[] names = config.getStringArray("client.nodes.node.name");</span> +<span class="fc" id="L319"> Map<String, UDDINode> nodes = new HashMap<String, UDDINode>();</span> +<span class="fc" id="L320"> log.debug("node names=" + names.length);</span> +<span class="fc bfc" id="L321" title="All 2 branches covered."> for (int i = 0; i < names.length; i++) {</span> +<span class="fc" id="L322"> UDDINode uddiNode = new UDDINode();</span> +<span class="fc" id="L323"> String nodeName = config.getString("client.nodes.node(" + i + ").name");</span> +<span class="fc" id="L324"> String[] propertyKeys = config.getStringArray("client.nodes.node(" + i + ").properties.property[@name]");</span> + +<span class="pc bpc" id="L326" title="1 of 4 branches missed."> if (propertyKeys != null && propertyKeys.length > 0) {</span> +<span class="fc bfc" id="L327" title="All 2 branches covered."> if (properties == null) {</span> +<span class="fc" id="L328"> properties = new Properties();</span> + } +<span class="fc bfc" id="L330" title="All 2 branches covered."> for (int p = 0; p < propertyKeys.length; p++) {</span> +<span class="fc" id="L331"> String name = config.getString("client.nodes.node(" + i + ").properties.property(" + p + ")[@name]");</span> +<span class="fc" id="L332"> String value = config.getString("client.nodes.node(" + i + ").properties.property(" + p + ")[@value]");</span> +<span class="fc" id="L333"> log.debug("Property: name=" + name + " value=" + value);</span> +<span class="fc" id="L334"> properties.put(name, value);</span> + } +<span class="fc" id="L336"> uddiNode.setProperties(properties);</span> + } + +<span class="fc" id="L339"> uddiNode.setHomeJUDDI(config.getBoolean("client.nodes.node(" + i + ")[@isHomeJUDDI]", false));</span> +<span class="fc" id="L340"> uddiNode.setName(TokenResolver.replaceTokens(config.getString("client.nodes.node(" + i + ").name"), properties));</span> +<span class="fc" id="L341"> uddiNode.setClientName(TokenResolver.replaceTokens(config.getString("client[@name]"), properties));</span> +<span class="fc" id="L342"> uddiNode.setDescription(TokenResolver.replaceTokens(config.getString("client.nodes.node(" + i + ").description"), properties));</span> +<span class="fc" id="L343"> uddiNode.setProxyTransport(TokenResolver.replaceTokens(config.getString("client.nodes.node(" + i + ").proxyTransport"), properties));</span> +<span class="fc" id="L344"> uddiNode.setInquiryUrl(TokenResolver.replaceTokens(config.getString("client.nodes.node(" + i + ").inquiryUrl"), properties));</span> +<span class="fc" id="L345"> uddiNode.setInquiryRESTUrl(TokenResolver.replaceTokens(config.getString("client.nodes.node(" + i + ").inquiryRESTUrl"), properties));</span> +<span class="fc" id="L346"> uddiNode.setPublishUrl(TokenResolver.replaceTokens(config.getString("client.nodes.node(" + i + ").publishUrl"), properties));</span> +<span class="fc" id="L347"> uddiNode.setCustodyTransferUrl(TokenResolver.replaceTokens(config.getString("client.nodes.node(" + i + ").custodyTransferUrl"), properties));</span> +<span class="fc" id="L348"> uddiNode.setSecurityUrl(TokenResolver.replaceTokens(config.getString("client.nodes.node(" + i + ").securityUrl"), properties));</span> +<span class="fc" id="L349"> uddiNode.setReplicationUrl(TokenResolver.replaceTokens(config.getString("client.nodes.node(" + i + ").replicationUrl"), properties));</span> +<span class="fc" id="L350"> uddiNode.setSubscriptionUrl(TokenResolver.replaceTokens(config.getString("client.nodes.node(" + i + ").subscriptionUrl"), properties));</span> +<span class="fc" id="L351"> uddiNode.setSubscriptionListenerUrl(TokenResolver.replaceTokens(config.getString("client.nodes.node(" + i + ").subscriptionListenerUrl"), properties));</span> +<span class="fc" id="L352"> uddiNode.setJuddiApiUrl(TokenResolver.replaceTokens(config.getString("client.nodes.node(" + i + ").juddiApiUrl"), properties));</span> +<span class="fc" id="L353"> uddiNode.setFactoryInitial(TokenResolver.replaceTokens(config.getString("client.nodes.node(" + i + ").javaNamingFactoryInitial"), properties));</span> +<span class="fc" id="L354"> uddiNode.setFactoryURLPkgs(TokenResolver.replaceTokens(config.getString("client.nodes.node(" + i + ").javaNamingFactoryUrlPkgs"), properties));</span> +<span class="fc" id="L355"> uddiNode.setFactoryNamingProvider(TokenResolver.replaceTokens(config.getString("client.nodes.node(" + i + ").javaNamingProviderUrl"), properties));</span> +<span class="fc" id="L356"> nodes.put(nodeName, uddiNode);</span> + } +<span class="fc" id="L358"> return nodes;</span> + } + + private Set<XRegistration> readXBusinessRegConfig(Configuration config, Map<String, UDDIClerk> clerks) + throws ConfigurationException { +<span class="fc" id="L363"> return readXRegConfig(config, clerks, "business");</span> + } + + private Set<XRegistration> readXServiceBindingRegConfig(Configuration config, Map<String, UDDIClerk> clerks) + throws ConfigurationException { +<span class="fc" id="L368"> return readXRegConfig(config, clerks, "servicebinding");</span> + } + + private Set<XRegistration> readXRegConfig(Configuration config, Map<String, UDDIClerk> clerks, String entityType) + throws ConfigurationException { +<span class="fc" id="L373"> String[] entityKeys = config.getStringArray("client.clerks.xregister." + entityType + "[@entityKey]");</span> +<span class="fc" id="L374"> Set<XRegistration> xRegistrations = new HashSet<XRegistration>();</span> +<span class="pc bpc" id="L375" title="1 of 2 branches missed."> if (entityKeys.length > 0) {</span> +<span class="nc" id="L376"> log.info("XRegistration " + entityKeys.length + " " + entityType + "Keys");</span> + } +<span class="pc bpc" id="L378" title="1 of 2 branches missed."> for (int i = 0; i < entityKeys.length; i++) {</span> +<span class="nc" id="L379"> XRegistration xRegistration = new XRegistration();</span> +<span class="nc" id="L380"> xRegistration.setEntityKey(config.getString("client.clerks.xregister." + entityType + "(" + i + ")[@entityKey]"));</span> + +<span class="nc" id="L382"> String fromClerkRef = config.getString("client.clerks.xregister." + entityType + "(" + i + ")[@fromClerk]");</span> +<span class="nc bnc" id="L383" title="All 2 branches missed."> if (!clerks.containsKey(fromClerkRef)) {</span> +<span class="nc" id="L384"> throw new ConfigurationException("Could not find fromClerk with name=" + fromClerkRef);</span> + } +<span class="nc" id="L386"> UDDIClerk fromClerk = clerks.get(fromClerkRef);</span> +<span class="nc" id="L387"> xRegistration.setFromClerk(fromClerk);</span> + +<span class="nc" id="L389"> String toClerkRef = config.getString("client.clerks.xregister." + entityType + "(" + i + ")[@toClerk]");</span> +<span class="nc bnc" id="L390" title="All 2 branches missed."> if (!clerks.containsKey(toClerkRef)) {</span> +<span class="nc" id="L391"> throw new ConfigurationException("Could not find toClerk with name=" + toClerkRef);</span> + } +<span class="nc" id="L393"> UDDIClerk toClerk = clerks.get(toClerkRef);</span> +<span class="nc" id="L394"> xRegistration.setToClerk(toClerk);</span> +<span class="nc" id="L395"> log.debug(xRegistration);</span> + +<span class="nc" id="L397"> xRegistrations.add(xRegistration);</span> + } +<span class="fc" id="L399"> return xRegistrations;</span> + } + + protected Map<String, UDDINode> getUDDINodes() { +<span class="nc" id="L403"> return uddiNodes;</span> + } + + /** + * gets the current configuration's node list Only a copy of these + * values are returned + * + * @return a list of nodes representing the config file as described + * @since 3.3 updated to return all fields + * @since 3.2 + */ + public List<Node> getUDDINodeList() { +<span class="fc" id="L415"> List<Node> ret = new ArrayList<Node>();</span> +<span class="fc" id="L416"> Iterator<UDDINode> it = uddiNodes.values().iterator();</span> +<span class="fc bfc" id="L417" title="All 2 branches covered."> while (it.hasNext()) {</span> +<span class="fc" id="L418"> UDDINode next = it.next();</span> +<span class="fc" id="L419"> Node n = new Node();</span> +<span class="fc" id="L420"> n.setClientName(next.getClientName());</span> +<span class="fc" id="L421"> n.setDescription(next.getDescription());</span> +<span class="fc" id="L422"> n.setName(next.getName());</span> +<span class="fc" id="L423"> n.setProxyTransport(next.getProxyTransport());</span> +<span class="fc" id="L424"> n.setCustodyTransferUrl(next.getCustodyTransferUrl());</span> +<span class="fc" id="L425"> n.setFactoryInitial(next.getFactoryInitial());</span> +<span class="fc" id="L426"> n.setFactoryNamingProvider(next.getFactoryNamingProvider());</span> +<span class="fc" id="L427"> n.setFactoryURLPkgs(next.getFactoryURLPkgs());</span> +<span class="fc" id="L428"> n.setInquiryUrl(next.getInquiryUrl());</span> +<span class="fc" id="L429"> n.setJuddiApiUrl(next.getJuddiApiUrl());</span> +<span class="fc" id="L430"> n.setPublishUrl(next.getPublishUrl());</span> +<span class="fc" id="L431"> n.setReplicationUrl(next.getReplicationUrl());</span> +<span class="fc" id="L432"> n.setSecurityUrl(next.getSecurityUrl());</span> +<span class="fc" id="L433"> n.setSubscriptionListenerUrl(next.getSubscriptionListenerUrl());</span> +<span class="fc" id="L434"> n.setSubscriptionUrl(next.getSubscriptionUrl());</span> +<span class="fc" id="L435"> ret.add(n);</span> +<span class="fc" id="L436"> }</span> +<span class="fc" id="L437"> return ret;</span> + } + + public UDDINode getHomeNode() throws ConfigurationException { +<span class="pc bpc" id="L441" title="1 of 2 branches missed."> if (uddiNodes == null) {</span> +<span class="nc" id="L442"> throw new ConfigurationException("The juddi client configuration "</span> + + "must contain at least one node element."); + } +<span class="fc bfc" id="L445" title="All 2 branches covered."> if (uddiNodes.values().size() == 1) {</span> +<span class="fc" id="L446"> return uddiNodes.values().iterator().next();</span> + } +<span class="fc" id="L448"> UDDINode ret = null;</span> +<span class="fc bfc" id="L449" title="All 2 branches covered."> for (UDDINode uddiNode : uddiNodes.values()) {</span> +<span class="fc bfc" id="L450" title="All 2 branches covered."> if (uddiNode.isHomeJUDDI()) {</span> +<span class="pc bpc" id="L451" title="1 of 2 branches missed."> if (ret != null) {</span> +<span class="nc" id="L452"> throw new ConfigurationException("Only one of the node elements in the client configuration needs to a 'isHomeJUDDI=\"true\"' attribute.");</span> + } +<span class="fc" id="L454"> ret = uddiNode;</span> + } +<span class="fc" id="L456"> }</span> +<span class="pc bpc" id="L457" title="1 of 2 branches missed."> if (ret != null) {</span> +<span class="fc" id="L458"> return ret;</span> + } +<span class="nc" id="L460"> throw new ConfigurationException("One of the node elements in the client configuration needs to a 'isHomeJUDDI=\"true\"' attribute.");</span> + } + + /** + * returns the named uddi node from config or throws if one is not found + * @param nodeName + * @return + * @throws ConfigurationException + */ + public UDDINode getUDDINode(String nodeName) throws ConfigurationException { +<span class="pc bpc" id="L470" title="1 of 2 branches missed."> if (!uddiNodes.containsKey(nodeName)) {</span> +<span class="nc" id="L471"> throw new ConfigurationException("Node '" + nodeName</span> +<span class="nc" id="L472"> + "' cannot be found in the config '" + getClientName() + "'");</span> + } +<span class="fc" id="L474"> return uddiNodes.get(nodeName);</span> + } + + public Map<String, UDDIClerk> getUDDIClerks() { +<span class="fc" id="L478"> return uddiClerks;</span> + } + + public Set<XRegistration> getXServiceBindingRegistrations() { +<span class="nc" id="L482"> return xServiceBindingRegistrations;</span> + } + + public Set<XRegistration> getXBusinessRegistrations() { +<span class="nc" id="L486"> return xBusinessRegistrations;</span> + } + + public Configuration getConfiguration() { +<span class="fc" id="L490"> return config;</span> + } + + public String getClientName() { +<span class="fc" id="L494"> return clientName;</span> + } + + @Deprecated + public String getClientCallbackUrl() { +<span class="nc" id="L499"> return clientCallbackUrl;</span> + } + + public String getConfigurationFile() { +<span class="nc" id="L503"> return configurationFile;</span> + } + + /** + * Used for WADL/WSDL to WSDL + * + * @return true/false + */ + public boolean isX_To_Wsdl_Ignore_SSL_Errors() { +<span class="fc" id="L512"> return this.config.getBoolean("client.XtoWsdl.IgnoreSSLErrors", false);</span> + } + + /** + * Fetches all digital signature related properties for the digital + * signature utility. warning, this will decrypt all passwords + * + * @return a properties object + * @throws Exception + * @see DigSigUtil + * @see Properties + */ + public Properties getDigitalSignatureConfiguration() throws Exception { +<span class="fc" id="L525"> Properties p = new Properties();</span> +<span class="fc" id="L526"> p.setProperty(DigSigUtil.CANONICALIZATIONMETHOD, this.config.getString("client.signature.canonicalizationMethod", CanonicalizationMethod.EXCLUSIVE));</span> +<span class="fc" id="L527"> p.setProperty(DigSigUtil.CHECK_TIMESTAMPS, ((Boolean) (this.config.getBoolean("client.signature.checkTimestamps", true))).toString());</span> +<span class="fc" id="L528"> p.setProperty(DigSigUtil.CHECK_REVOCATION_STATUS_CRL, ((Boolean) (this.config.getBoolean("client.signature.checkRevocationCRL", true))).toString());</span> +<span class="fc" id="L529"> p.setProperty(DigSigUtil.CHECK_REVOCATION_STATUS_OCSP, ((Boolean) (this.config.getBoolean("client.signature.checkRevocationOCSP", true))).toString());</span> +<span class="fc" id="L530"> p.setProperty(DigSigUtil.CHECK_TRUST_CHAIN, ((Boolean) (this.config.getBoolean("client.signature.checkTrust", true))).toString());</span> + +<span class="fc" id="L532"> p.setProperty(DigSigUtil.SIGNATURE_KEYSTORE_FILE, this.config.getString("client.signature.signingKeyStorePath", ""));</span> +<span class="fc" id="L533"> p.setProperty(DigSigUtil.SIGNATURE_KEYSTORE_FILETYPE, this.config.getString("client.signature.signingKeyStoreType", ""));</span> + +<span class="pc bpc" id="L535" title="1 of 2 branches missed."> if (this.config.getBoolean("client.signature.signingKeyPassword[@isPasswordEncrypted]", false)) {</span> +<span class="nc" id="L536"> String enc = this.config.getString("client.signature.signingKeyPassword", "");</span> +<span class="nc" id="L537"> String prov = this.config.getString("client.signature.signingKeyPassword[@cryptoProvider]", "");</span> +<span class="nc" id="L538"> p.setProperty(DigSigUtil.SIGNATURE_KEYSTORE_KEY_PASSWORD, CryptorFactory.getCryptor(prov).decrypt(enc));</span> +<span class="nc" id="L539"> p.setProperty(DigSigUtil.SIGNATURE_KEYSTORE_KEY_PASSWORD_WAS_ENC, "true");</span> +<span class="nc" id="L540"> p.setProperty(DigSigUtil.SIGNATURE_KEYSTORE_KEY_PASSWORD_PROVIDER, prov);</span> +<span class="nc" id="L541"> p.setProperty(DigSigUtil.SIGNATURE_KEYSTORE_KEY_PASSWORD_CIPHER, enc);</span> +<span class="nc" id="L542"> } else {</span> +<span class="fc" id="L543"> log.warn("Hey, you should consider encrypting your key password!");</span> +<span class="fc" id="L544"> p.setProperty(DigSigUtil.SIGNATURE_KEYSTORE_KEY_PASSWORD, this.config.getString("client.signature.signingKeyPassword", ""));</span> +<span class="fc" id="L545"> p.setProperty(DigSigUtil.SIGNATURE_KEYSTORE_KEY_PASSWORD_WAS_ENC, "false");</span> + } +<span class="pc bpc" id="L547" title="1 of 2 branches missed."> if (this.config.getBoolean("client.signature.signingKeyStoreFilePassword[@isPasswordEncrypted]", false)) {</span> +<span class="nc" id="L548"> String enc = this.config.getString("client.signature.signingKeyStoreFilePassword", "");</span> +<span class="nc" id="L549"> String prov = this.config.getString("client.signature.signingKeyStoreFilePassword[@cryptoProvider]", "");</span> +<span class="nc" id="L550"> p.setProperty(DigSigUtil.SIGNATURE_KEYSTORE_FILE_PASSWORD, CryptorFactory.getCryptor(prov).decrypt(enc));</span> +<span class="nc" id="L551"> p.setProperty(DigSigUtil.SIGNATURE_KEYSTORE_FILE_PASSWORD_PROVIDER, (prov));</span> +<span class="nc" id="L552"> p.setProperty(DigSigUtil.SIGNATURE_KEYSTORE_FILE_PASSWORD_CIPHER, (enc));</span> +<span class="nc" id="L553"> } else {</span> +<span class="fc" id="L554"> log.warn("Hey, you should consider encrypting your keystore password!");</span> +<span class="fc" id="L555"> p.setProperty(DigSigUtil.SIGNATURE_KEYSTORE_FILE_PASSWORD, this.config.getString("client.signature.signingKeyStoreFilePassword", ""));</span> + } + +<span class="fc" id="L558"> p.setProperty(DigSigUtil.SIGNATURE_KEYSTORE_KEY_ALIAS, this.config.getString("client.signature.signingKeyAlias", ""));</span> +<span class="fc" id="L559"> p.setProperty(DigSigUtil.SIGNATURE_METHOD, this.config.getString("client.signature.signatureMethod", "http://www.w3.org/2000/09/xmldsig#rsa-sha1"));</span> +<span class="fc" id="L560"> p.setProperty(DigSigUtil.SIGNATURE_OPTION_CERT_INCLUSION_SUBJECTDN, this.config.getString("client.signature.keyInfoInclusionSubjectDN", "true"));</span> +<span class="fc" id="L561"> p.setProperty(DigSigUtil.SIGNATURE_OPTION_CERT_INCLUSION_BASE64, this.config.getString("client.signature.keyInfoInclusionBase64PublicKey", "true"));</span> +<span class="fc" id="L562"> p.setProperty(DigSigUtil.SIGNATURE_OPTION_CERT_INCLUSION_SERIAL, this.config.getString("client.signature.keyInfoInclusionSerial", "true"));</span> + +<span class="fc" id="L564"> p.setProperty(DigSigUtil.SIGNATURE_OPTION_DIGEST_METHOD, this.config.getString("client.signature.digestMethod", "http://www.w3.org/2000/09/xmldsig#sha1"));</span> + +<span class="fc" id="L566"> p.setProperty(DigSigUtil.TRUSTSTORE_FILE, this.config.getString("client.signature.trustStorePath", ""));</span> +<span class="fc" id="L567"> p.setProperty(DigSigUtil.TRUSTSTORE_FILETYPE, this.config.getString("client.signature.trustStoreType", ""));</span> + +<span class="pc bpc" id="L569" title="1 of 2 branches missed."> if (this.config.getBoolean("client.signature.trustStorePassword[@isPasswordEncrypted]", false)) {</span> +<span class="nc" id="L570"> String enc = this.config.getString("client.signature.trustStorePassword", "");</span> +<span class="nc" id="L571"> String prov = this.config.getString("client.signature.trustStorePassword[@cryptoProvider]", "");</span> +<span class="nc" id="L572"> p.setProperty(DigSigUtil.TRUSTSTORE_FILE_PASSWORD, CryptorFactory.getCryptor(prov).decrypt(enc));</span> +<span class="nc" id="L573"> p.setProperty(DigSigUtil.TRUSTSTORE_FILE_PASSWORD_PROVIDER, (prov));</span> +<span class="nc" id="L574"> p.setProperty(DigSigUtil.TRUSTSTORE_FILE_PASSWORD_CIPHER, (enc));</span> +<span class="nc" id="L575"> } else {</span> +<span class="fc" id="L576"> log.warn("Hey, you should consider encrypting your trust store password!");</span> +<span class="fc" id="L577"> p.setProperty(DigSigUtil.TRUSTSTORE_FILE_PASSWORD, this.config.getString("client.signature.trustStorePassword", ""));</span> + } + +<span class="fc" id="L580"> return p;</span> + } + + /** + * adds a new node to the client configuration section. Don't forget to + * call save to persist the changes + * + * @param node + * @throws org.apache.commons.configuration.ConfigurationException + * @since 3.3 + */ + public void addUDDINode(UDDINode node) throws ConfigurationException { +<span class="pc bpc" id="L592" title="1 of 2 branches missed."> if (node == null) {</span> +<span class="nc" id="L593"> throw new ConfigurationException("The new node is null");</span> + } +<span class="pc bpc" id="L595" title="1 of 2 branches missed."> if (this.uddiNodes.containsKey(node.getName())) {</span> +<span class="nc" id="L596"> throw new ConfigurationException("Node '" + node.getName() + "' already existings in the collection!");</span> + } +<span class="pc bpc" id="L598" title="3 of 4 branches missed."> if (node.getClientName() == null || "".equalsIgnoreCase(node.getClientName())) {</span> +<span class="fc" id="L599"> log.info("ClientName wasn't specified, I'll configure it with the defaults");</span> +<span class="fc" id="L600"> node.setClientName(this.clientName);</span> + } +<span class="pc bpc" id="L602" title="2 of 4 branches missed."> if (node.getName() == null || "".equalsIgnoreCase(node.getName())) {</span> +<span class="nc" id="L603"> throw new ConfigurationException("Node Name wasn't specified. It cannot be null");</span> + } +<span class="fc" id="L605"> this.uddiNodes.put(node.getName(), node);</span> + +<span class="fc" id="L607"> }</span> + + /** + * removes the named node from the client configuration section. don't + * forget to save to persist the changes + * + * @param name expecting the Node name, not the "clientName" + * @throws ConfigurationException + */ + public void removeUDDINode(String name) throws ConfigurationException { +<span class="nc bnc" id="L617" title="All 2 branches missed."> if (this.uddiNodes.containsKey(name)) {</span> +<span class="nc" id="L618"> this.uddiNodes.remove(name);</span> + } +<span class="nc" id="L620"> }</span> + + /** + * performs some basic validation tests on the config setting that was + * read from file + */ + private void validateConfig() throws ConfigurationException { +<span class="pc bpc" id="L627" title="1 of 2 branches missed."> if (config == null) {</span> +<span class="nc" id="L628"> throw new ConfigurationException("config is null!");</span> + } +<span class="pc bpc" id="L630" title="1 of 2 branches missed."> if (uddiNodes == null) {</span> +<span class="nc" id="L631"> throw new ConfigurationException("nodes is null!");</span> + } +<span class="pc bpc" id="L633" title="1 of 2 branches missed."> if (uddiClerks == null) {</span> +<span class="nc" id="L634"> throw new ConfigurationException("clerks is null!");</span> + } +<span class="fc" id="L636"> Iterator<Map.Entry<String, UDDIClerk>> it = uddiClerks.entrySet().iterator();</span> +<span class="fc bfc" id="L637" title="All 2 branches covered."> while (it.hasNext()) {</span> +<span class="fc" id="L638"> Map.Entry<String, UDDIClerk> next = it.next();</span> +<span class="pc bpc" id="L639" title="1 of 2 branches missed."> if (next.getValue().uddiNode == null) {</span> +<span class="nc" id="L640"> throw new ConfigurationException("clerk " + next.getValue().name + " references a node that doesn't exist!");</span> + } +<span class="fc" id="L642"> }</span> +<span class="fc" id="L643"> }</span> + + private void addCurrentNodeConfig(Configuration cc) { + +<span class="fc" id="L647"> cc.addProperty("[@xmlns]", config.getProperty("[@xmlns]"));</span> +<span class="fc" id="L648"> cc.addProperty("client(0)[@name]", clientName);</span> +<span class="fc" id="L649"> Iterator<Map.Entry<String, UDDINode>> iterator = uddiNodes.entrySet().iterator();</span> +<span class="fc" id="L650"> int i = 0;</span> +<span class="fc bfc" id="L651" title="All 2 branches covered."> while (iterator.hasNext()) {</span> +<span class="fc" id="L652"> log.debug("node names=" + uddiNodes.size());</span> + +<span class="fc" id="L654"> UDDINode uddiNode = iterator.next().getValue();</span> + +<span class="fc" id="L656"> Properties properties = uddiNode.getProperties();</span> + +<span class="fc bfc" id="L658" title="All 2 branches covered."> if (properties == null) {</span> +<span class="fc" id="L659"> properties = new Properties();</span> + } +<span class="fc" id="L661"> Iterator<Map.Entry<Object, Object>> iterator1 = properties.entrySet().iterator();</span> +<span class="fc" id="L662"> int x = 0;</span> +<span class="fc bfc" id="L663" title="All 2 branches covered."> while (iterator1.hasNext()) {</span> +<span class="fc" id="L664"> Map.Entry<Object, Object> next = iterator1.next();</span> +<span class="fc" id="L665"> cc.addProperty("client(0).nodes.node(" + i + ").properties.property(" + x + ")[@name]", next.getKey());</span> +<span class="fc" id="L666"> cc.addProperty("client(0).nodes.node(" + i + ").properties.property(" + x + ")[@value]", next.getValue());</span> + +<span class="fc" id="L668"> log.debug("Property: name=" + next.getKey() + " value=" + next.getValue());</span> + +<span class="fc" id="L670"> x++;</span> +<span class="fc" id="L671"> }</span> + +<span class="fc" id="L673"> cc.addProperty("client(0).nodes.node(" + i + ")[@isHomeJUDDI]", uddiNode.isHomeJUDDI());</span> +<span class="fc" id="L674"> cc.addProperty("client(0).nodes.node(" + i + ").name", uddiNode.getName());</span> +<span class="fc" id="L675"> cc.addProperty("client(0).nodes.node(" + i + ").description", uddiNode.getDescription());</span> +<span class="fc" id="L676"> cc.addProperty("client(0).nodes.node(" + i + ").proxyTransport", uddiNode.getProxyTransport());</span> +<span class="fc" id="L677"> cc.addProperty("client(0).nodes.node(" + i + ").inquiryUrl", uddiNode.getInquiryUrl());</span> +<span class="fc" id="L678"> cc.addProperty("client(0).nodes.node(" + i + ").inquiryRESTUrl", uddiNode.getInquiry_REST_Url());</span> +<span class="fc" id="L679"> cc.addProperty("client(0).nodes.node(" + i + ").publishUrl", uddiNode.getPublishUrl());</span> +<span class="fc" id="L680"> cc.addProperty("client(0).nodes.node(" + i + ").custodyTransferUrl", uddiNode.getCustodyTransferUrl());</span> +<span class="fc" id="L681"> cc.addProperty("client(0).nodes.node(" + i + ").securityUrl", uddiNode.getSecurityUrl());</span> +<span class="fc" id="L682"> cc.addProperty("client(0).nodes.node(" + i + ").replicationUrl", uddiNode.getReplicationUrl());</span> +<span class="fc" id="L683"> cc.addProperty("client(0).nodes.node(" + i + ").subscriptionUrl", uddiNode.getSubscriptionUrl());</span> +<span class="fc" id="L684"> cc.addProperty("client(0).nodes.node(" + i + ").juddiApiUrl", uddiNode.getJuddiApiUrl());</span> +<span class="fc" id="L685"> cc.addProperty("client(0).nodes.node(" + i + ").subscriptionListenerUrl", uddiNode.getSubscriptionListenerUrl());</span> +<span class="fc" id="L686"> cc.addProperty("client(0).nodes.node(" + i + ").javaNamingFactoryInitial", uddiNode.getFactoryInitial());</span> +<span class="fc" id="L687"> cc.addProperty("client(0).nodes.node(" + i + ").javaNamingFactoryUrlPkgs", uddiNode.getFactoryURLPkgs());</span> +<span class="fc" id="L688"> cc.addProperty("client(0).nodes.node(" + i + ").javaNamingProviderUrl", uddiNode.getFactoryNamingProvider());</span> + +<span class="fc" id="L690"> i++;</span> +<span class="fc" id="L691"> }</span> + +<span class="fc" id="L693"> }</span> + + private void addCurrentClerks(Configuration cc) { + +<span class="fc" id="L697"> Iterator<Map.Entry<String, UDDIClerk>> iterator = uddiClerks.entrySet().iterator();</span> +<span class="fc" id="L698"> clientName = config.getString("client[@name]");</span> +<span class="fc" id="L699"> clientCallbackUrl = config.getString("client(0)[@callbackUrl]");</span> + +<span class="fc" id="L701"> cc.addProperty("client(0).clerks[@registerOnStartup]", isRegisterOnStartup());</span> +<span class="fc" id="L702"> int i = 0;</span> +<span class="fc bfc" id="L703" title="All 2 branches covered."> while (iterator.hasNext()) {</span> + +<span class="fc" id="L705"> UDDIClerk uddiClerk = iterator.next().getValue();</span> +<span class="fc" id="L706"> cc.addProperty("client(0).clerks.clerk(" + i + ")[@name]", uddiClerk.getName());</span> + //registerOnStartup +<span class="fc" id="L708"> cc.addProperty("client(0).clerks.clerk(" + i + ")[@node]", uddiClerk.getUDDINode().getName());</span> + +<span class="fc" id="L710"> cc.addProperty("client(0).clerks.clerk(" + i + ")[@publisher]", uddiClerk.getPublisher());</span> +<span class="fc" id="L711"> cc.addProperty("client(0).clerks.clerk(" + i + ")[@password]", uddiClerk.getRawPassword());</span> + +<span class="fc" id="L713"> cc.addProperty("client(0).clerks.clerk(" + i + ")[@isPasswordEncrypted]", uddiClerk.getIsPasswordEncrypted());</span> + +<span class="fc" id="L715"> cc.addProperty("client(0).clerks.clerk(" + i + ")[@cryptoProvider]", uddiClerk.getCryptoProvider());</span> + +<span class="fc" id="L717"> String[] classes = uddiClerk.getClassWithAnnotations();</span> +<span class="pc bpc" id="L718" title="1 of 2 branches missed."> if (classes != null) {</span> +<span class="fc bfc" id="L719" title="All 2 branches covered."> for (int x = 0; x < classes.length; x++) {</span> +<span class="fc" id="L720"> cc.addProperty("client(0).clerks.clerk(" + i + ").class(" + x + ")", classes[x]);</span> + } + } + +<span class="fc" id="L724"> UDDIClerk.WSDL[] wsdls = uddiClerk.getWsdls();</span> +<span class="fc bfc" id="L725" title="All 2 branches covered."> if (wsdls != null) {</span> +<span class="fc bfc" id="L726" title="All 2 branches covered."> for (int w = 0; w < wsdls.length; w++) {</span> +<span class="fc" id="L727"> cc.addProperty("client(0).clerks.clerk(" + i + ").wsdl(" + w + ")", wsdls[w].getFileName());</span> +<span class="fc" id="L728"> cc.addProperty("client(0).clerks.clerk(" + i + ").wsdl(" + w + ")[@businessKey]", wsdls[w].getBusinessKey());</span> +<span class="fc" id="L729"> cc.addProperty("client(0).clerks.clerk(" + i + ").wsdl(" + w + ")[@keyDomain]", wsdls[w].getKeyDomain());</span> + } + } +<span class="fc" id="L732"> i++;</span> +<span class="fc" id="L733"> }</span> + +<span class="pc bpc" id="L735" title="1 of 2 branches missed."> if (xBusinessRegistrations != null) {</span> +<span class="fc" id="L736"> Iterator<XRegistration> iterator1 = xBusinessRegistrations.iterator();</span> +<span class="fc" id="L737"> int x = 0;</span> +<span class="pc bpc" id="L738" title="1 of 2 branches missed."> while (iterator1.hasNext()) {</span> +<span class="nc" id="L739"> XRegistration next = iterator1.next();</span> +<span class="nc" id="L740"> cc.addProperty("client(0).clerks.business(" + x + ")[@fromClerk]", next.getFromClerk().name);</span> +<span class="nc" id="L741"> cc.addProperty("client(0).clerks.business(" + x + ")[@toClerk]", next.getToClerk().name);</span> +<span class="nc" id="L742"> cc.addProperty("client(0).clerks.business(" + x + ")[@entityKey]", next.getEntityKey());</span> +<span class="nc" id="L743"> x++;</span> +<span class="nc" id="L744"> }</span> + } +<span class="pc bpc" id="L746" title="1 of 2 branches missed."> if (xServiceBindingRegistrations != null) {</span> +<span class="fc" id="L747"> Iterator<XRegistration> iterator1 = xServiceBindingRegistrations.iterator();</span> +<span class="fc" id="L748"> int x = 0;</span> +<span class="pc bpc" id="L749" title="1 of 2 branches missed."> while (iterator1.hasNext()) {</span> +<span class="nc" id="L750"> XRegistration next = iterator1.next();</span> +<span class="nc" id="L751"> cc.addProperty("client(0).clerks.servicebinding(" + x + ")[@fromClerk]", next.getFromClerk().name);</span> +<span class="nc" id="L752"> cc.addProperty("client(0).clerks.servicebinding(" + x + ")[@toClerk]", next.getToClerk().name);</span> +<span class="nc" id="L753"> cc.addProperty("client(0).clerks.servicebinding(" + x + ")[@entityKey]", next.getEntityKey());</span> +<span class="nc" id="L754"> x++;</span> +<span class="nc" id="L755"> }</span> + } +<span class="fc" id="L757"> }</span> + + private void addSubscriptionCallback(Configuration cc) { +<span class="pc bpc" id="L760" title="1 of 2 branches missed."> if (this.config.containsKey(SubscriptionCallbackListener.PROPERTY_AUTOREG_BT)) {</span> +<span class="fc" id="L761"> cc.addProperty(SubscriptionCallbackListener.PROPERTY_AUTOREG_BT, this.config.getProperty(SubscriptionCallbackListener.PROPERTY_AUTOREG_BT));</span> + } +<span class="pc bpc" id="L763" title="1 of 2 branches missed."> if (this.config.containsKey(SubscriptionCallbackListener.PROPERTY_AUTOREG_SERVICE_KEY)) {</span> +<span class="fc" id="L764"> cc.addProperty(SubscriptionCallbackListener.PROPERTY_AUTOREG_SERVICE_KEY, this.config.getProperty(SubscriptionCallbackListener.PROPERTY_AUTOREG_SERVICE_KEY));</span> + } +<span class="pc bpc" id="L766" title="1 of 2 branches missed."> if (this.config.containsKey(SubscriptionCallbackListener.PROPERTY_KEYDOMAIN)) {</span> +<span class="fc" id="L767"> cc.addProperty(SubscriptionCallbackListener.PROPERTY_KEYDOMAIN, this.config.getProperty(SubscriptionCallbackListener.PROPERTY_KEYDOMAIN));</span> + } +<span class="pc bpc" id="L769" title="1 of 2 branches missed."> if (this.config.containsKey(SubscriptionCallbackListener.PROPERTY_LISTENURL)) {</span> +<span class="fc" id="L770"> cc.addProperty(SubscriptionCallbackListener.PROPERTY_LISTENURL, this.config.getProperty(SubscriptionCallbackListener.PROPERTY_LISTENURL));</span> + } +<span class="pc bpc" id="L772" title="1 of 2 branches missed."> if (this.config.containsKey(SubscriptionCallbackListener.PROPERTY_NODE)) {</span> +<span class="nc" id="L773"> cc.addProperty(SubscriptionCallbackListener.PROPERTY_NODE, this.config.getProperty(SubscriptionCallbackListener.PROPERTY_NODE));</span> + } +<span class="pc bpc" id="L775" title="1 of 2 branches missed."> if (this.config.containsKey(SubscriptionCallbackListener.PROPERTY_SIGNATURE_BEHAVIOR)) {</span> +<span class="fc" id="L776"> cc.addProperty(SubscriptionCallbackListener.PROPERTY_SIGNATURE_BEHAVIOR, this.config.getProperty(SubscriptionCallbackListener.PROPERTY_SIGNATURE_BEHAVIOR));</span> + } +<span class="fc" id="L778"> }</span> + + private void addDigitalSubscription(Configuration cc) throws Exception { +<span class="fc" id="L781"> Properties p = this.getDigitalSignatureConfiguration();</span> +<span class="fc" id="L782"> Iterator<Map.Entry<Object, Object>> it = p.entrySet().iterator();</span> +<span class="fc bfc" id="L783" title="All 2 branches covered."> while (it.hasNext()) {</span> +<span class="fc" id="L784"> Map.Entry<Object, Object> next = it.next();</span> +<span class="fc" id="L785"> String key = (String) next.getKey();</span> +<span class="fc" id="L786"> Object val = next.getValue();</span> +<span class="pc bpc" id="L787" title="1 of 2 branches missed."> if (val == null) {</span> +<span class="nc" id="L788"> continue;</span> + } +<span class="fc bfc" id="L790" title="All 2 branches covered."> if (key.equalsIgnoreCase(DigSigUtil.CANONICALIZATIONMETHOD)) {</span> +<span class="fc" id="L791"> cc.addProperty("client(0).signature.canonicalizationMethod", val);</span> +<span class="fc bfc" id="L792" title="All 2 branches covered."> } else if (key.equalsIgnoreCase(DigSigUtil.CHECK_TIMESTAMPS)) {</span> +<span class="fc" id="L793"> cc.addProperty("client(0).signature.checkTimestamps", val);</span> +<span class="fc bfc" id="L794" title="All 2 branches covered."> } else if (key.equalsIgnoreCase(DigSigUtil.CHECK_REVOCATION_STATUS_CRL)) {</span> +<span class="fc" id="L795"> cc.addProperty("client(0).signature.checkRevocationCRL", val);</span> +<span class="fc bfc" id="L796" title="All 2 branches covered."> } else if (key.equalsIgnoreCase(DigSigUtil.CHECK_REVOCATION_STATUS_OCSP)) {</span> +<span class="fc" id="L797"> cc.addProperty("client(0).signature.checkRevocationOCSP", val);</span> +<span class="fc bfc" id="L798" title="All 2 branches covered."> } else if (key.equalsIgnoreCase(DigSigUtil.CHECK_TRUST_CHAIN)) {</span> +<span class="fc" id="L799"> cc.addProperty("client(0).signature.checkTrust", val);</span> +<span class="fc bfc" id="L800" title="All 2 branches covered."> } else if (key.equalsIgnoreCase(DigSigUtil.SIGNATURE_KEYSTORE_FILE)) {</span> +<span class="fc" id="L801"> cc.addProperty("client(0).signature.signingKeyStorePath", val);</span> +<span class="fc bfc" id="L802" title="All 2 branches covered."> } else if (key.equalsIgnoreCase(DigSigUtil.SIGNATURE_KEYSTORE_FILETYPE)) {</span> +<span class="fc" id="L803"> cc.addProperty("client(0).signature.signingKeyStoreType", val);</span> +<span class="fc bfc" id="L804" title="All 2 branches covered."> } else if (key.equalsIgnoreCase(DigSigUtil.SIGNATURE_KEYSTORE_KEY_PASSWORD)) {</span> +<span class="fc" id="L805"> cc.addProperty("client(0).signature.signingKeyPassword", val);</span> +<span class="fc bfc" id="L806" title="All 2 branches covered."> } else if (key.equalsIgnoreCase(DigSigUtil.SIGNATURE_KEYSTORE_KEY_PASSWORD_WAS_ENC)) {</span> +<span class="fc" id="L807"> cc.addProperty("client(0).signature.signingKeyPassword[@isPasswordEncrypted]", val);</span> +<span class="pc bpc" id="L808" title="1 of 2 branches missed."> } else if (key.equalsIgnoreCase(DigSigUtil.SIGNATURE_KEYSTORE_KEY_PASSWORD_PROVIDER)) {</span> +<span class="nc" id="L809"> cc.addProperty("client(0).signature.signingKeyPassword[@cryptoProvider]", val);</span> +<span class="pc bpc" id="L810" title="1 of 2 branches missed."> } else if (key.equalsIgnoreCase(DigSigUtil.SIGNATURE_KEYSTORE_KEY_PASSWORD_CIPHER)) {</span> +<span class="nc" id="L811"> cc.addProperty("client(0).signature.signingKeyPassword", val);</span> +<span class="fc bfc" id="L812" title="All 2 branches covered."> } else if (key.equalsIgnoreCase(DigSigUtil.SIGNATURE_KEYSTORE_KEY_ALIAS)) {</span> +<span class="fc" id="L813"> cc.addProperty("client(0).signature.signingKeyAlias", val);</span> +<span class="fc bfc" id="L814" title="All 2 branches covered."> } else if (key.equalsIgnoreCase(DigSigUtil.SIGNATURE_METHOD)) {</span> +<span class="fc" id="L815"> cc.addProperty("client(0).signature.signatureMethod", val);</span> +<span class="fc bfc" id="L816" title="All 2 branches covered."> } else if (key.equalsIgnoreCase(DigSigUtil.SIGNATURE_OPTION_CERT_INCLUSION_SUBJECTDN)) {</span> +<span class="fc" id="L817"> cc.addProperty("client(0).signature.keyInfoInclusionSubjectDN", val);</span> +<span class="fc bfc" id="L818" title="All 2 branches covered."> } else if (key.equalsIgnoreCase(DigSigUtil.SIGNATURE_OPTION_CERT_INCLUSION_BASE64)) {</span> +<span class="fc" id="L819"> cc.addProperty("client(0).signature.keyInfoInclusionBase64PublicKey", val);</span> +<span class="fc bfc" id="L820" title="All 2 branches covered."> } else if (key.equalsIgnoreCase(DigSigUtil.SIGNATURE_OPTION_CERT_INCLUSION_SERIAL)) {</span> +<span class="fc" id="L821"> cc.addProperty("client(0).signature.keyInfoInclusionSerial", val);</span> +<span class="fc bfc" id="L822" title="All 2 branches covered."> } else if (key.equalsIgnoreCase(DigSigUtil.SIGNATURE_OPTION_DIGEST_METHOD)) {</span> +<span class="fc" id="L823"> cc.addProperty("client(0).signature.digestMethod", val);</span> +<span class="fc bfc" id="L824" title="All 2 branches covered."> } else if (key.equalsIgnoreCase(DigSigUtil.TRUSTSTORE_FILE)) {</span> +<span class="fc" id="L825"> cc.addProperty("client(0).signature.trustStorePath", val);</span> +<span class="fc bfc" id="L826" title="All 2 branches covered."> } else if (key.equalsIgnoreCase(DigSigUtil.TRUSTSTORE_FILETYPE)) {</span> +<span class="fc" id="L827"> cc.addProperty("client(0).signature.trustStoreType", val);</span> +<span class="pc bpc" id="L828" title="1 of 2 branches missed."> } else if (key.equalsIgnoreCase(DigSigUtil.SIGNATURE_KEYSTORE_FILE_PASSWORD_WASENC)) {</span> +<span class="nc" id="L829"> cc.addProperty("client(0).signature.signingKeyStoreFilePassword[@isPasswordEncrypted]", val);</span> +<span class="pc bpc" id="L830" title="1 of 2 branches missed."> } else if (key.equalsIgnoreCase(DigSigUtil.SIGNATURE_KEYSTORE_FILE_PASSWORD_PROVIDER)) {</span> +<span class="nc" id="L831"> cc.addProperty("client(0).signature.signingKeyStoreFilePassword[@cryptoProvider]", val);</span> +<span class="pc bpc" id="L832" title="1 of 2 branches missed."> } else if (key.equalsIgnoreCase(DigSigUtil.TRUSTSTORE_FILE_PASSWORD_WASENC)) {</span> +<span class="nc" id="L833"> cc.addProperty("client(0).signature.trustStorePassword[@isPasswordEncrypted]", val);</span> +<span class="pc bpc" id="L834" title="1 of 2 branches missed."> } else if (key.equalsIgnoreCase(DigSigUtil.TRUSTSTORE_FILE_PASSWORD_PROVIDER)) {</span> +<span class="nc" id="L835"> cc.addProperty("client(0).signature.trustStorePassword[@cryptoProvider]", val);</span> + } + +<span class="fc" id="L838"> }</span> + +<span class="pc bpc" id="L840" title="1 of 2 branches missed."> if (p.getProperty(DigSigUtil.SIGNATURE_KEYSTORE_FILE_PASSWORD_WASENC, "false").equalsIgnoreCase("true")) {</span> +<span class="nc" id="L841"> cc.addProperty("client(0).signature.signingKeyStoreFilePassword", p.getProperty(DigSigUtil.SIGNATURE_KEYSTORE_FILE_PASSWORD_CIPHER));</span> + } else { +<span class="fc" id="L843"> cc.addProperty("client(0).signature.signingKeyStoreFilePassword", p.getProperty(DigSigUtil.SIGNATURE_KEYSTORE_FILE_PASSWORD));</span> + } + +<span class="pc bpc" id="L846" title="1 of 2 branches missed."> if (p.getProperty(DigSigUtil.TRUSTSTORE_FILE_PASSWORD_WASENC, "false").equalsIgnoreCase("true")) {</span> +<span class="nc" id="L847"> cc.addProperty("client(0).signature.trustStorePassword", p.getProperty(DigSigUtil.TRUSTSTORE_FILE_PASSWORD_CIPHER));</span> + } else { +<span class="fc" id="L849"> cc.addProperty("client(0).signature.trustStorePassword", p.getProperty(DigSigUtil.TRUSTSTORE_FILE_PASSWORD));</span> + } + +<span class="pc bpc" id="L852" title="1 of 2 branches missed."> if (p.getProperty(DigSigUtil.SIGNATURE_KEYSTORE_KEY_PASSWORD_WAS_ENC, "false").equalsIgnoreCase("true")) {</span> +<span class="nc" id="L853"> cc.addProperty("client(0).signature.signingKeyPassword", p.getProperty(DigSigUtil.SIGNATURE_KEYSTORE_KEY_PASSWORD_CIPHER));</span> + } else { +<span class="fc" id="L855"> cc.addProperty("client(0).signature.signingKeyPassword", p.getProperty(DigSigUtil.SIGNATURE_KEYSTORE_KEY_PASSWORD));</span> + } + +<span class="fc" id="L858"> }</span> + + private void addXRegistration(Configuration cc) { + +<span class="fc" id="L862"> cc.addProperty("client.XtoWsdl.IgnoreSSLErrors", isX_To_Wsdl_Ignore_SSL_Errors());</span> +<span class="fc" id="L863"> }</span> + +} +</pre><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.7.9.201702052155</span></div></body></html> \ No newline at end of file
http://git-wip-us.apache.org/repos/asf/juddi/blob/06b2a02d/jacoco/juddi-client/jacoco-ut/org.apache.juddi.v3.client.config/Constants.html ---------------------------------------------------------------------- diff --git a/jacoco/juddi-client/jacoco-ut/org.apache.juddi.v3.client.config/Constants.html b/jacoco/juddi-client/jacoco-ut/org.apache.juddi.v3.client.config/Constants.html new file mode 100644 index 0000000..db99046 --- /dev/null +++ b/jacoco/juddi-client/jacoco-ut/org.apache.juddi.v3.client.config/Constants.html @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="en"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>Constants</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">jUDDI Client side Code</a> > <a href="index.html" class="el_package">org.apache.juddi.v3.client.config</a> > <span class="el_class">Constants</span></div><h1>Constants</h1><table class="coverage" cellspacing="0" id="coveragetable"><thead ><tr><td class="sortable" id="a" onclick="toggleSort(this)">Element</td><td >class="down sortable bar" id="b" onclick="toggleSort(this)">Missed >Instructions</td><td class="sortable ctr2" id="c" >onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" >onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" >id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" >onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" >onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" >onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" >onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" >onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" >onclick="toggleSort(this)">Methods</td></tr></thead><tfoot><tr><td>Total</td><td > class="bar">3 of 3</td><td class="ctr2">0%</td><td class="bar">0 of >0</td><td class="ctr2">n/a</td><td class="ctr1">1</td><td >class="ctr2">1</td><td class ="ctr1">1</td><td class="ctr2">1</td><td class="ctr1">1</td><td class="ctr2">1</td></tr></tfoot><tbody><tr><td id="a0"><a href="Constants.java.html#L28" class="el_method">Constants()</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="3" alt="3"/></td><td class="ctr2" id="c0">0%</td><td class="bar" id="d0"/><td class="ctr2" id="e0">n/a</td><td class="ctr1" id="f0">1</td><td class="ctr2" id="g0">1</td><td class="ctr1" id="h0">1</td><td class="ctr2" id="i0">1</td><td class="ctr1" id="j0">1</td><td class="ctr2" id="k0">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.7.9.201702052155</span></div></body></html> \ No newline at end of file http://git-wip-us.apache.org/repos/asf/juddi/blob/06b2a02d/jacoco/juddi-client/jacoco-ut/org.apache.juddi.v3.client.config/Constants.java.html ---------------------------------------------------------------------- diff --git a/jacoco/juddi-client/jacoco-ut/org.apache.juddi.v3.client.config/Constants.java.html b/jacoco/juddi-client/jacoco-ut/org.apache.juddi.v3.client.config/Constants.java.html new file mode 100644 index 0000000..1b811ff --- /dev/null +++ b/jacoco/juddi-client/jacoco-ut/org.apache.juddi.v3.client.config/Constants.java.html @@ -0,0 +1,32 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="en"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>Constants.java</title><link rel="stylesheet" href="../jacoco-resources/prettify.css" type="text/css"/><script type="text/javascript" src="../jacoco-resources/prettify.js"></script></head><body onload="window['PR_TAB_WIDTH']=4;prettyPrint()"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">jUDDI Client side Code</a> > <a href="index.source.html" class="el_package">org.apache.juddi.v3.client.config</a> > <span class="el_sourc e">Constants.java</span></div><h1>Constants.java</h1><pre class="source lang-java linenums">/* + * Copyright 2001-2009 The Apache Software Foundation. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ + +package org.apache.juddi.v3.client.config; + +import org.apache.juddi.v3.client.UDDIConstants; + +/** + * Contains all the juddi client constants + * + * @author <a href="mailto:[email protected]">Kurt T Stam</a> + * @see UDDIConstants + */ +<span class="nc" id="L28">public class Constants {</span> + + public static final String API_V3_NAMESPACE = "urn:uddi-org:api_v3_portType"; +} +</pre><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.7.9.201702052155</span></div></body></html> \ No newline at end of file --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
