001: /*
002: * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
003: *
004: * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved.
005: *
006: * The contents of this file are subject to the terms of either the GNU
007: * General Public License Version 2 only ("GPL") or the Common Development
008: * and Distribution License("CDDL") (collectively, the "License"). You
009: * may not use this file except in compliance with the License. You can obtain
010: * a copy of the License at https://glassfish.dev.java.net/public/CDDL+GPL.html
011: * or glassfish/bootstrap/legal/LICENSE.txt. See the License for the specific
012: * language governing permissions and limitations under the License.
013: *
014: * When distributing the software, include this License Header Notice in each
015: * file and include the License file at glassfish/bootstrap/legal/LICENSE.txt.
016: * Sun designates this particular file as subject to the "Classpath" exception
017: * as provided by Sun in the GPL Version 2 section of the License file that
018: * accompanied this code. If applicable, add the following below the License
019: * Header, with the fields enclosed by brackets [] replaced by your own
020: * identifying information: "Portions Copyrighted [year]
021: * [name of copyright owner]"
022: *
023: * Contributor(s):
024: *
025: * If you wish your version of this file to be governed by only the CDDL or
026: * only the GPL Version 2, indicate your decision by adding "[Contributor]
027: * elects to include this software in this distribution under the [CDDL or GPL
028: * Version 2] license." If you don't indicate a single choice of license, a
029: * recipient has the option to distribute your version of this file under
030: * either the CDDL, the GPL Version 2 or to extend the choice of license to
031: * its licensees as provided above. However, if you add GPL Version 2 code
032: * and therefore, elected the GPL Version 2 license, then the option applies
033: * only if the new code is made subject to such option by the copyright
034: * holder.
035: */
036:
037: package com.sun.xml.ws.transport.tcp.util;
038:
039: import com.sun.istack.NotNull;
040: import java.util.List;
041: import javax.xml.namespace.QName;
042:
043: /**
044: * @author Alexey Stashok
045: */
046: public final class ChannelSettings {
047:
048: private List<String> negotiatedMimeTypes;
049:
050: private List<String> negotiatedParams;
051:
052: private int channelId;
053:
054: private QName wsServiceName;
055:
056: private WSTCPURI targetWSURI;
057:
058: public ChannelSettings() {
059: }
060:
061: public ChannelSettings(@NotNull
062: final List<String> negotiatedMimeTypes, @NotNull
063: final List<String> negotiatedParams, final int channelId,
064: final QName wsServiceName, final WSTCPURI targetWSURI) {
065: this .negotiatedMimeTypes = negotiatedMimeTypes;
066: this .negotiatedParams = negotiatedParams;
067: this .channelId = channelId;
068: this .wsServiceName = wsServiceName;
069: this .targetWSURI = targetWSURI;
070: }
071:
072: public @NotNull
073: List<String> getNegotiatedMimeTypes() {
074: return negotiatedMimeTypes;
075: }
076:
077: public void setNegotiatedMimeTypes(@NotNull
078: final List<String> negotiatedMimeTypes) {
079: this .negotiatedMimeTypes = negotiatedMimeTypes;
080: }
081:
082: public @NotNull
083: List<String> getNegotiatedParams() {
084: return negotiatedParams;
085: }
086:
087: public void setNegotiatedParams(@NotNull
088: final List<String> negotiatedParams) {
089: this .negotiatedParams = negotiatedParams;
090: }
091:
092: public @NotNull
093: WSTCPURI getTargetWSURI() {
094: return targetWSURI;
095: }
096:
097: public void setTargetWSURI(@NotNull
098: final WSTCPURI targetWSURI) {
099: this .targetWSURI = targetWSURI;
100: }
101:
102: public int getChannelId() {
103: return channelId;
104: }
105:
106: public void setChannelId(final int channelId) {
107: this .channelId = channelId;
108: }
109:
110: public @NotNull
111: QName getWSServiceName() {
112: return wsServiceName;
113: }
114:
115: public void setWSServiceName(@NotNull
116: final QName wsServiceName) {
117: this .wsServiceName = wsServiceName;
118: }
119:
120: public String toString() {
121: StringBuffer sb = new StringBuffer(200);
122: sb.append("TargetURI: ");
123: sb.append(targetWSURI);
124: sb.append(" wsServiceName: ");
125: sb.append(wsServiceName);
126: sb.append(" channelId: ");
127: sb.append(channelId);
128: sb.append(" negotiatedParams: ");
129: sb.append(negotiatedParams);
130: sb.append(" negotiatedMimeTypes: ");
131: sb.append(negotiatedMimeTypes);
132:
133: return sb.toString();
134: }
135: }
|