1 5 package com.tc.config.schema.test; 6 7 import com.tc.config.schema.builder.WebApplicationConfigBuilder; 8 9 import java.util.HashMap ; 10 import java.util.Map ; 11 12 15 public class WebApplicationConfigBuilderImpl extends BaseConfigBuilder implements WebApplicationConfigBuilder { 16 17 private static final String TAG_NAME = "web-application"; 18 private static final String ATTRIBUTE_NAME = "synchronous-write"; 19 20 private Map attributes; 21 22 public WebApplicationConfigBuilderImpl() { 23 super(5, new String [] { TAG_NAME }); 24 attributes = new HashMap (); 25 } 26 27 public void setWebApplicationName(String name) { 28 setProperty(TAG_NAME, name); 29 } 30 31 public void setWebApplicationAttributes(Map attributes) { 32 this.attributes.putAll(attributes); 33 } 34 35 public String toString() { 36 return openElement(TAG_NAME, attributes) + propertyAsString(TAG_NAME) + closeElement(TAG_NAME); 37 } 38 39 } 40 | Popular Tags |