@Test public void should_generate_a_container_node_object() { final ChameleonTargetConfiguration chameleonTargetConfiguration = new ChameleonTargetConfiguration("tomcat:8.0.0:managed"); final Element containerDefinition = (Element) chameleonTargetConfiguration.getContainerDefinitionAsXml(); final NodeList properties = containerDefinition.getElementsByTagName("property"); assertThat(properties.getLength()) .isEqualTo(1); assertThat(properties.item(0).getTextContent()) .isEqualTo("tomcat:8.0.0:managed"); }
public Node getContainerDefinitionAsXml() { Document containerDocument = DomManipulation.createDocumentFromContainerTemplate(); final NodeList properties = containerDocument.getElementsByTagName("property"); final Element chameleonTargetProperty = findChameleonTargetProperty(properties); if (chameleonTargetProperty == null) { throw new IllegalArgumentException("No property chameleonTarget found in container template"); } chameleonTargetProperty.setTextContent(toChameleonTarget()); updateCustomProperties(containerDocument); return containerDocument.getFirstChild(); }
ChameleonTargetConfiguration { public Node getContainerDefinitionAsXml() { Document containerDocument = DomManipulation.createDocumentFromContainerTemplate(); final NodeList properties = containerDocument.getElementsByTagName("property"); final Element chameleonTargetProperty = findChameleonTargetProperty(properties); if (chameleonTargetProperty == null) { throw new IllegalArgumentException("No property chameleonTarget found in container template"); } chameleonTargetProperty.setTextContent(toChameleonTarget()); updateCustomProperties(containerDocument); return containerDocument.getFirstChild(); } }
ChameleonTargetConfiguration { public Node getContainerDefinitionAsXml() { Document containerDocument = DomManipulation.createDocumentFromContainerTemplate(); final NodeList properties = containerDocument.getElementsByTagName("property"); final Element chameleonTargetProperty = findChameleonTargetProperty(properties); if (chameleonTargetProperty == null) { throw new IllegalArgumentException("No property chameleonTarget found in container template"); } chameleonTargetProperty.setTextContent(toChameleonTarget()); updateCustomProperties(containerDocument); return containerDocument.getFirstChild(); } protected  ChameleonTargetConfiguration(String value); protected  ChameleonTargetConfiguration(String container, String version, Mode mode,
        Map<String, String> customProperties); }
ChameleonTargetConfiguration { public Node getContainerDefinitionAsXml() { Document containerDocument = DomManipulation.createDocumentFromContainerTemplate(); final NodeList properties = containerDocument.getElementsByTagName("property"); final Element chameleonTargetProperty = findChameleonTargetProperty(properties); if (chameleonTargetProperty == null) { throw new IllegalArgumentException("No property chameleonTarget found in container template"); } chameleonTargetProperty.setTextContent(toChameleonTarget()); updateCustomProperties(containerDocument); return containerDocument.getFirstChild(); } protected  ChameleonTargetConfiguration(String value); protected  ChameleonTargetConfiguration(String container, String version, Mode mode,
        Map<String, String> customProperties); static ChameleonTargetConfiguration from(ChameleonTarget chameleonTarget); ChameleonTargetConfiguration importConfiguration(ChameleonTargetConfiguration other); Properties getContainerDefinitionAsProperties(); Node getContainerDefinitionAsXml(); String getContainer(); String getVersion(); Mode getMode(); Map<String, String> getCustomProperties(); String toChameleonTarget(); }
ChameleonTargetConfiguration { public Node getContainerDefinitionAsXml() { Document containerDocument = DomManipulation.createDocumentFromContainerTemplate(); final NodeList properties = containerDocument.getElementsByTagName("property"); final Element chameleonTargetProperty = findChameleonTargetProperty(properties); if (chameleonTargetProperty == null) { throw new IllegalArgumentException("No property chameleonTarget found in container template"); } chameleonTargetProperty.setTextContent(toChameleonTarget()); updateCustomProperties(containerDocument); return containerDocument.getFirstChild(); } protected  ChameleonTargetConfiguration(String value); protected  ChameleonTargetConfiguration(String container, String version, Mode mode,
        Map<String, String> customProperties); static ChameleonTargetConfiguration from(ChameleonTarget chameleonTarget); ChameleonTargetConfiguration importConfiguration(ChameleonTargetConfiguration other); Properties getContainerDefinitionAsProperties(); Node getContainerDefinitionAsXml(); String getContainer(); String getVersion(); Mode getMode(); Map<String, String> getCustomProperties(); String toChameleonTarget(); static final int VERSION; static final int MODE; }