Package com.sun.xml.ws.api.message.saaj
Class SAAJMessageHeaders
- java.lang.Object
-
- com.sun.xml.ws.api.message.saaj.SAAJMessageHeaders
-
- All Implemented Interfaces:
MessageHeaders
public class SAAJMessageHeaders extends Object implements MessageHeaders
-
-
Constructor Summary
Constructors Constructor Description SAAJMessageHeaders(jakarta.xml.soap.SOAPMessage sm, SOAPVersion version)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanadd(Header header)booleanaddOrReplace(Header header)List<Header>asList()ReturnsHeaderinstances in aList.Headerget(String nsUri, String localName, boolean markAsUnderstood)Headerget(QName name, boolean markAsUnderstood)Iterator<Header>getHeaders()Iterator<Header>getHeaders(String nsUri, boolean markAsUnderstood)Get all headers in specified namespaceIterator<Header>getHeaders(String nsUri, String localName, boolean markAsUnderstood)Iterator<Header>getHeaders(QName headerName, boolean markAsUnderstood)Set<QName>getNotUnderstoodHeaders(Set<String> roles, Set<QName> knownHeaders, WSBinding binding)Returns a Set of QNames of headers that satisfy ALL the following conditions: (a) Have mustUnderstand = true (b) have NOT been explicitly marked as understood (c) If roles argument is non-null, the header has isIgnorable = false for the roles argument and SOAP version (d) If non-null binding is passed in, are NOT understood by the binding (e) If (d) is met, the header is NOT in the knownHeaders list passed inSet<QName>getUnderstoodHeaders()Return a Set of QNames of headers that have been explicitly marked as understood.booleanhasHeaders()booleanisUnderstood(int index)booleanisUnderstood(Header header)True if the header has been explicitly marked understood, false otherwisebooleanisUnderstood(String nsUri, String localName)True if the header has been explicitly marked understood, false otherwisebooleanisUnderstood(QName name)True if the header has been explicitly marked understood, false otherwiseHeaderremove(String nsUri, String localName)Headerremove(QName name)voidreplace(Header old, Header header)voidunderstood(Header header)voidunderstood(String nsUri, String localName)voidunderstood(QName qName)
-
-
-
Constructor Detail
-
SAAJMessageHeaders
public SAAJMessageHeaders(jakarta.xml.soap.SOAPMessage sm, SOAPVersion version)
-
-
Method Detail
-
understood
public void understood(Header header)
- Specified by:
understoodin interfaceMessageHeaders
-
understood
public void understood(String nsUri, String localName)
- Specified by:
understoodin interfaceMessageHeaders
-
understood
public void understood(QName qName)
- Specified by:
understoodin interfaceMessageHeaders
-
isUnderstood
public boolean isUnderstood(Header header)
Description copied from interface:MessageHeadersTrue if the header has been explicitly marked understood, false otherwise- Specified by:
isUnderstoodin interfaceMessageHeaders- Returns:
-
isUnderstood
public boolean isUnderstood(String nsUri, String localName)
Description copied from interface:MessageHeadersTrue if the header has been explicitly marked understood, false otherwise- Specified by:
isUnderstoodin interfaceMessageHeaders- Returns:
-
isUnderstood
public boolean isUnderstood(QName name)
Description copied from interface:MessageHeadersTrue if the header has been explicitly marked understood, false otherwise- Specified by:
isUnderstoodin interfaceMessageHeaders- Returns:
-
isUnderstood
public boolean isUnderstood(int index)
-
get
public Header get(String nsUri, String localName, boolean markAsUnderstood)
- Specified by:
getin interfaceMessageHeaders
-
get
public Header get(QName name, boolean markAsUnderstood)
- Specified by:
getin interfaceMessageHeaders
-
getHeaders
public Iterator<Header> getHeaders(QName headerName, boolean markAsUnderstood)
- Specified by:
getHeadersin interfaceMessageHeaders
-
getHeaders
public Iterator<Header> getHeaders(String nsUri, String localName, boolean markAsUnderstood)
- Specified by:
getHeadersin interfaceMessageHeaders
-
getHeaders
public Iterator<Header> getHeaders(String nsUri, boolean markAsUnderstood)
Description copied from interface:MessageHeadersGet all headers in specified namespace- Specified by:
getHeadersin interfaceMessageHeaders- Returns:
-
add
public boolean add(Header header)
- Specified by:
addin interfaceMessageHeaders
-
remove
public Header remove(QName name)
- Specified by:
removein interfaceMessageHeaders
-
remove
public Header remove(String nsUri, String localName)
- Specified by:
removein interfaceMessageHeaders
-
addOrReplace
public boolean addOrReplace(Header header)
Description copied from interface:MessageHeadersReplaces an existingHeaderor adds a newHeader.Order doesn't matter in headers, so this method does not make any guarantee as to where the new header is inserted.
- Specified by:
addOrReplacein interfaceMessageHeaders- Returns:
- always true. Don't use the return value.
-
replace
public void replace(Header old, Header header)
- Specified by:
replacein interfaceMessageHeaders
-
getUnderstoodHeaders
public Set<QName> getUnderstoodHeaders()
Description copied from interface:MessageHeadersReturn a Set of QNames of headers that have been explicitly marked as understood. If none have been marked, this method could return null- Specified by:
getUnderstoodHeadersin interfaceMessageHeaders
-
getNotUnderstoodHeaders
public Set<QName> getNotUnderstoodHeaders(Set<String> roles, Set<QName> knownHeaders, WSBinding binding)
Description copied from interface:MessageHeadersReturns a Set of QNames of headers that satisfy ALL the following conditions: (a) Have mustUnderstand = true (b) have NOT been explicitly marked as understood (c) If roles argument is non-null, the header has isIgnorable = false for the roles argument and SOAP version (d) If non-null binding is passed in, are NOT understood by the binding (e) If (d) is met, the header is NOT in the knownHeaders list passed in- Specified by:
getNotUnderstoodHeadersin interfaceMessageHeaders- Returns:
-
getHeaders
public Iterator<Header> getHeaders()
- Specified by:
getHeadersin interfaceMessageHeaders
-
hasHeaders
public boolean hasHeaders()
- Specified by:
hasHeadersin interfaceMessageHeaders
-
asList
public List<Header> asList()
Description copied from interface:MessageHeadersReturnsHeaderinstances in aList.- Specified by:
asListin interfaceMessageHeaders- Returns:
ListcontainingHeaderinstances
-
-