00001
00027 package org.objectweb.jonas_ejb.deployment.xml;
00028
00029 import org.objectweb.jonas_lib.deployment.xml.AbsElement;
00036 public class AsContextMapping extends AbsElement {
00037
00041 private String authMethod = null;
00042
00046 private String realm = null;
00047
00051 private String required = null;
00052
00053
00057 public String getAuthMethod() {
00058 return authMethod;
00059 }
00063 public void setAuthMethod(String authMethod) {
00064 this.authMethod = authMethod;
00065 }
00069 public String getRealm() {
00070 return realm;
00071 }
00075 public void setRealm(String realm) {
00076 this.realm = realm;
00077 }
00081 public String getRequired() {
00082 return required;
00083 }
00087 public void setRequired(String required) {
00088 this.required = required;
00089 }
00093 public AsContextMapping() {
00094 super();
00095 }
00096
00097
00098
00104 public String toXML(int indent) {
00105 StringBuffer sb = new StringBuffer();
00106 sb.append(indent(indent));
00107 sb.append("<as-context>\n");
00108
00109 indent += 2;
00110
00111
00112 sb.append(xmlElement(authMethod, "auth-method", indent));
00113
00114 sb.append(xmlElement(realm, "realm", indent));
00115
00116 sb.append(xmlElement(required, "required", indent));
00117 indent -= 2;
00118 sb.append(indent(indent));
00119 sb.append("</as-context>\n");
00120
00121 return sb.toString();
00122 }
00123 }