Thu, 31 Aug 2017 15:18:52 +0800
merge
aoqi@0 | 1 | /* |
aoqi@0 | 2 | * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. |
aoqi@0 | 3 | * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
aoqi@0 | 4 | * |
aoqi@0 | 5 | * This code is free software; you can redistribute it and/or modify it |
aoqi@0 | 6 | * under the terms of the GNU General Public License version 2 only, as |
aoqi@0 | 7 | * published by the Free Software Foundation. Oracle designates this |
aoqi@0 | 8 | * particular file as subject to the "Classpath" exception as provided |
aoqi@0 | 9 | * by Oracle in the LICENSE file that accompanied this code. |
aoqi@0 | 10 | * |
aoqi@0 | 11 | * This code is distributed in the hope that it will be useful, but WITHOUT |
aoqi@0 | 12 | * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
aoqi@0 | 13 | * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
aoqi@0 | 14 | * version 2 for more details (a copy is included in the LICENSE file that |
aoqi@0 | 15 | * accompanied this code). |
aoqi@0 | 16 | * |
aoqi@0 | 17 | * You should have received a copy of the GNU General Public License version |
aoqi@0 | 18 | * 2 along with this work; if not, write to the Free Software Foundation, |
aoqi@0 | 19 | * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
aoqi@0 | 20 | * |
aoqi@0 | 21 | * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
aoqi@0 | 22 | * or visit www.oracle.com if you need additional information or have any |
aoqi@0 | 23 | * questions. |
aoqi@0 | 24 | */ |
aoqi@0 | 25 | |
aoqi@0 | 26 | package com.sun.xml.internal.ws.addressing; |
aoqi@0 | 27 | |
aoqi@0 | 28 | import javax.xml.namespace.QName; |
aoqi@0 | 29 | |
aoqi@0 | 30 | import com.sun.xml.internal.ws.api.addressing.AddressingVersion; |
aoqi@0 | 31 | |
aoqi@0 | 32 | /** |
aoqi@0 | 33 | * Constants for W3C WS-Addressing version |
aoqi@0 | 34 | * |
aoqi@0 | 35 | * @author Arun Gupta |
aoqi@0 | 36 | */ |
aoqi@0 | 37 | public interface W3CAddressingConstants { |
aoqi@0 | 38 | public static final String WSA_NAMESPACE_NAME = "http://www.w3.org/2005/08/addressing"; |
aoqi@0 | 39 | public static final String WSA_NAMESPACE_WSDL_NAME = "http://www.w3.org/2006/05/addressing/wsdl"; |
aoqi@0 | 40 | |
aoqi@0 | 41 | public static final String WSAW_SERVICENAME_NAME = "ServiceName"; |
aoqi@0 | 42 | public static final String WSAW_INTERFACENAME_NAME = "InterfaceName"; |
aoqi@0 | 43 | public static final String WSAW_ENDPOINTNAME_NAME = "EndpointName"; |
aoqi@0 | 44 | |
aoqi@0 | 45 | public static final String WSA_REFERENCEPROPERTIES_NAME = "ReferenceParameters"; |
aoqi@0 | 46 | public static final QName WSA_REFERENCEPROPERTIES_QNAME = new QName(WSA_NAMESPACE_NAME, WSA_REFERENCEPROPERTIES_NAME); |
aoqi@0 | 47 | |
aoqi@0 | 48 | public static final String WSA_REFERENCEPARAMETERS_NAME = "ReferenceParameters"; |
aoqi@0 | 49 | public static final QName WSA_REFERENCEPARAMETERS_QNAME = new QName(WSA_NAMESPACE_NAME, WSA_REFERENCEPARAMETERS_NAME); |
aoqi@0 | 50 | |
aoqi@0 | 51 | public static final String WSA_METADATA_NAME = "Metadata"; |
aoqi@0 | 52 | public static final QName WSA_METADATA_QNAME = new QName(WSA_NAMESPACE_NAME, WSA_METADATA_NAME); |
aoqi@0 | 53 | |
aoqi@0 | 54 | public static final String WSA_ADDRESS_NAME = "Address"; |
aoqi@0 | 55 | public static final QName WSA_ADDRESS_QNAME = new QName(WSA_NAMESPACE_NAME, WSA_ADDRESS_NAME); |
aoqi@0 | 56 | |
aoqi@0 | 57 | public static final String WSA_ANONYMOUS_ADDRESS = WSA_NAMESPACE_NAME + "/anonymous"; |
aoqi@0 | 58 | public static final String WSA_NONE_ADDRESS = WSA_NAMESPACE_NAME + "/none"; |
aoqi@0 | 59 | |
aoqi@0 | 60 | public static final String WSA_DEFAULT_FAULT_ACTION = WSA_NAMESPACE_NAME + "/fault"; |
aoqi@0 | 61 | |
aoqi@0 | 62 | public static final String WSA_EPR_NAME = "EndpointReference"; |
aoqi@0 | 63 | public static final QName WSA_EPR_QNAME = new QName(WSA_NAMESPACE_NAME, WSA_EPR_NAME); |
aoqi@0 | 64 | |
aoqi@0 | 65 | |
aoqi@0 | 66 | public static final String WSAW_USING_ADDRESSING_NAME = "UsingAddressing"; |
aoqi@0 | 67 | public static final QName WSAW_USING_ADDRESSING_QNAME = new QName(WSA_NAMESPACE_WSDL_NAME, WSAW_USING_ADDRESSING_NAME); |
aoqi@0 | 68 | |
aoqi@0 | 69 | public static final QName INVALID_MAP_QNAME = new QName(WSA_NAMESPACE_NAME, "InvalidAddressingHeader"); |
aoqi@0 | 70 | public static final QName MAP_REQUIRED_QNAME = new QName(WSA_NAMESPACE_NAME, "MessageAddressingHeaderRequired"); |
aoqi@0 | 71 | public static final QName DESTINATION_UNREACHABLE_QNAME = new QName(WSA_NAMESPACE_NAME, "DestinationUnreachable"); |
aoqi@0 | 72 | public static final QName ACTION_NOT_SUPPORTED_QNAME = new QName(WSA_NAMESPACE_NAME, "ActionNotSupported"); |
aoqi@0 | 73 | public static final QName ENDPOINT_UNAVAILABLE_QNAME = new QName(WSA_NAMESPACE_NAME, "EndpointUnavailable"); |
aoqi@0 | 74 | |
aoqi@0 | 75 | public static final String ACTION_NOT_SUPPORTED_TEXT = "The \"%s\" cannot be processed at the receiver"; |
aoqi@0 | 76 | public static final String DESTINATION_UNREACHABLE_TEXT = "No route can be determined to reach %s"; |
aoqi@0 | 77 | public static final String ENDPOINT_UNAVAILABLE_TEXT = "The endpoint is unable to process the message at this time"; |
aoqi@0 | 78 | public static final String INVALID_MAP_TEXT = "A header representing a Message Addressing Property is not valid and the message cannot be processed"; |
aoqi@0 | 79 | public static final String MAP_REQUIRED_TEXT = "A required header representing a Message Addressing Property is not present"; |
aoqi@0 | 80 | |
aoqi@0 | 81 | public static final QName PROBLEM_ACTION_QNAME = new QName(WSA_NAMESPACE_NAME, "ProblemAction"); |
aoqi@0 | 82 | public static final QName PROBLEM_HEADER_QNAME_QNAME = new QName(WSA_NAMESPACE_NAME, "ProblemHeaderQName"); |
aoqi@0 | 83 | public static final QName FAULT_DETAIL_QNAME = new QName(WSA_NAMESPACE_NAME, "FaultDetail"); |
aoqi@0 | 84 | |
aoqi@0 | 85 | // Fault subsubcode when an invalid address is specified. |
aoqi@0 | 86 | public static final QName INVALID_ADDRESS_SUBCODE = new QName(WSA_NAMESPACE_NAME, "InvalidAddress", |
aoqi@0 | 87 | AddressingVersion.W3C.getPrefix()); |
aoqi@0 | 88 | |
aoqi@0 | 89 | // Fault subsubcode when an invalid header was expected to be EndpointReference but was not valid. |
aoqi@0 | 90 | public static final QName INVALID_EPR = new QName(WSA_NAMESPACE_NAME, "InvalidEPR", AddressingVersion.W3C.getPrefix()); |
aoqi@0 | 91 | |
aoqi@0 | 92 | // Fault subsubcode when greater than expected number of the specified header is received. |
aoqi@0 | 93 | public static final QName INVALID_CARDINALITY = new QName(WSA_NAMESPACE_NAME, "InvalidCardinality", |
aoqi@0 | 94 | AddressingVersion.W3C.getPrefix()); |
aoqi@0 | 95 | |
aoqi@0 | 96 | // Fault subsubcode when an invalid header was expected to be EndpointReference but did not contain address. |
aoqi@0 | 97 | public static final QName MISSING_ADDRESS_IN_EPR = new QName(WSA_NAMESPACE_NAME, "MissingAddressInEPR", |
aoqi@0 | 98 | AddressingVersion.W3C.getPrefix()); |
aoqi@0 | 99 | |
aoqi@0 | 100 | // Fault subsubcode when a header contains a message id that was a duplicate of one already received. |
aoqi@0 | 101 | public static final QName DUPLICATE_MESSAGEID = new QName(WSA_NAMESPACE_NAME, "DuplicateMessageID", |
aoqi@0 | 102 | AddressingVersion.W3C.getPrefix()); |
aoqi@0 | 103 | |
aoqi@0 | 104 | // Fault subsubcode when <code>Action</code> and <code>SOAPAction</code> for the mesage did not match. |
aoqi@0 | 105 | public static final QName ACTION_MISMATCH = new QName(WSA_NAMESPACE_NAME, "ActionMismatch", |
aoqi@0 | 106 | AddressingVersion.W3C.getPrefix()); |
aoqi@0 | 107 | |
aoqi@0 | 108 | // Fault subsubcode when the only address supported is the anonymous address. |
aoqi@0 | 109 | public static final QName ONLY_ANONYMOUS_ADDRESS_SUPPORTED = new QName(WSA_NAMESPACE_NAME, "OnlyAnonymousAddressSupported", |
aoqi@0 | 110 | AddressingVersion.W3C.getPrefix()); |
aoqi@0 | 111 | |
aoqi@0 | 112 | //Fault subsubcode when anonymous address is not supported. |
aoqi@0 | 113 | public static final QName ONLY_NON_ANONYMOUS_ADDRESS_SUPPORTED = new QName(WSA_NAMESPACE_NAME, "OnlyNonAnonymousAddressSupported", |
aoqi@0 | 114 | AddressingVersion.W3C.getPrefix()); |
aoqi@0 | 115 | |
aoqi@0 | 116 | public static final String ANONYMOUS_EPR = "<EndpointReference xmlns=\"http://www.w3.org/2005/08/addressing\">\n" + |
aoqi@0 | 117 | " <Address>http://www.w3.org/2005/08/addressing/anonymous</Address>\n" + |
aoqi@0 | 118 | "</EndpointReference>"; |
aoqi@0 | 119 | } |