01: /*
02: * $Id: MimeHeader.java,v 1.4 2006/03/30 00:59:38 ofung Exp $
03: * $Revision: 1.4 $
04: * $Date: 2006/03/30 00:59:38 $
05: */
06:
07: /*
08: * The contents of this file are subject to the terms
09: * of the Common Development and Distribution License
10: * (the License). You may not use this file except in
11: * compliance with the License.
12: *
13: * You can obtain a copy of the license at
14: * https://glassfish.dev.java.net/public/CDDLv1.0.html.
15: * See the License for the specific language governing
16: * permissions and limitations under the License.
17: *
18: * When distributing Covered Code, include this CDDL
19: * Header Notice in each file and include the License file
20: * at https://glassfish.dev.java.net/public/CDDLv1.0.html.
21: * If applicable, add the following below the CDDL Header,
22: * with the fields enclosed by brackets [] replaced by
23: * you own identifying information:
24: * "Portions Copyrighted [year] [name of copyright owner]"
25: *
26: * Copyright 2006 Sun Microsystems Inc. All Rights Reserved
27: */
28: package javax.xml.soap;
29:
30: /**
31: * An object that stores a MIME header name and its value. One or more
32: * <code>MimeHeader</code> objects may be contained in a <code>MimeHeaders</code>
33: * object.
34: *
35: * @see MimeHeaders
36: */
37: public class MimeHeader {
38:
39: private String name;
40: private String value;
41:
42: /**
43: * Constructs a <code>MimeHeader</code> object initialized with the given
44: * name and value.
45: *
46: * @param name a <code>String</code> giving the name of the header
47: * @param value a <code>String</code> giving the value of the header
48: */
49: public MimeHeader(String name, String value) {
50: this .name = name;
51: this .value = value;
52: }
53:
54: /**
55: * Returns the name of this <code>MimeHeader</code> object.
56: *
57: * @return the name of the header as a <code>String</code>
58: */
59: public String getName() {
60: return name;
61: }
62:
63: /**
64: * Returns the value of this <code>MimeHeader</code> object.
65: *
66: * @return the value of the header as a <code>String</code>
67: */
68: public String getValue() {
69: return value;
70: }
71: }
|