001: /**
002: * JOnAS: Java(TM) Open Application Server
003: * Copyright (C) 1999 Bull S.A.
004: * Contact: jonas-team@objectweb.org
005: *
006: * This library is free software; you can redistribute it and/or
007: *
008: * modify it under the terms of the GNU Lesser General Public
009: * License as published by the Free Software Foundation; either
010: * version 2.1 of the License, or 1any later version.
011: *
012: * This library is distributed in the hope that it will be useful,
013: * but WITHOUT ANY WARRANTY; without even the implied warranty of
014: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
015: * Lesser General Public License for more details.
016: *
017: * You should have received a copy of the GNU Lesser General Public
018: * License along with this library; if not, write to the Free Software
019: * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
020: * USA
021: *
022: * Initial developer: JOnAS team
023: * --------------------------------------------------------------------------
024: * $Id: TransportConfigMapping.java 5876 2004-12-08 14:05:09Z benoitf $
025: * --------------------------------------------------------------------------
026: */package org.objectweb.jonas_ejb.deployment.xml;
027:
028: import org.objectweb.jonas_lib.deployment.xml.AbsElement;
029:
030: /**
031: * This class defines the implementation of the element transport-config
032: *
033: * @author JOnAS team
034: */
035:
036: public class TransportConfigMapping extends AbsElement {
037:
038: /**
039: * integrity
040: */
041: private String integrity = null;
042:
043: /**
044: * confidentiality
045: */
046: private String confidentiality = null;
047:
048: /**
049: * establish-trust-in-target
050: */
051: private String establishTrustInTarget = null;
052:
053: /**
054: * establish-trust-in-client
055: */
056: private String establishTrustInClient = null;
057:
058: /**
059: * @return Returns the confidentiality.
060: */
061: public String getConfidentiality() {
062: return confidentiality;
063: }
064:
065: /**
066: * @param confidentiality The confidentiality to set.
067: */
068: public void setConfidentiality(String confidentiality) {
069: this .confidentiality = confidentiality;
070: }
071:
072: /**
073: * @return Returns the establishTrustInClient.
074: */
075: public String getEstablishTrustInClient() {
076: return establishTrustInClient;
077: }
078:
079: /**
080: * @param establishTrustInClient The establishTrustInClient to set.
081: */
082: public void setEstablishTrustInClient(String establishTrustInClient) {
083: this .establishTrustInClient = establishTrustInClient;
084: }
085:
086: /**
087: * @return Returns the establishTrustInTarget.
088: */
089: public String getEstablishTrustInTarget() {
090: return establishTrustInTarget;
091: }
092:
093: /**
094: * @param establishTrustInTarget The establishTrustInTarget to set.
095: */
096: public void setEstablishTrustInTarget(String establishTrustInTarget) {
097: this .establishTrustInTarget = establishTrustInTarget;
098: }
099:
100: /**
101: * @return Returns the integrity.
102: */
103: public String getIntegrity() {
104: return integrity;
105: }
106:
107: /**
108: * @param integrity The integrity to set.
109: */
110: public void setIntegrity(String integrity) {
111: this .integrity = integrity;
112: }
113:
114: /**
115: * Constructor
116: */
117: public TransportConfigMapping() {
118: super ();
119: }
120:
121: /**
122: * Represents this element by it's XML description.
123: * @param indent use this indent for prexifing XML representation.
124: * @return the XML description of this object.
125: */
126: public String toXML(int indent) {
127: StringBuffer sb = new StringBuffer();
128: sb.append(indent(indent));
129: sb.append("<transport-config>\n");
130:
131: indent += 2;
132:
133: // integrity
134: sb.append(xmlElement(integrity, "integrity", indent));
135: // confidentiality
136: sb
137: .append(xmlElement(confidentiality, "confidentiality",
138: indent));
139: // establish-trust-in-target
140: sb.append(xmlElement(establishTrustInTarget,
141: "establish-trust-in-target", indent));
142: // establish-trust-in-client
143: sb.append(xmlElement(establishTrustInClient,
144: "establish-trust-in-client", indent));
145: indent -= 2;
146: sb.append(indent(indent));
147: sb.append("</transport-config>\n");
148:
149: return sb.toString();
150: }
151: }
|