< prev index next >
src/java.xml.ws/share/classes/com/sun/xml/internal/messaging/saaj/soap/impl/HeaderElementImpl.java
Print this page
@@ -1,7 +1,7 @@
/*
- * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2017, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
@@ -56,77 +56,86 @@
protected abstract boolean getRelayAttributeValue(String str);
protected abstract String getRelayLiteralValue(boolean mu);
protected abstract String getActorOrRole();
+ @Override
public void setParentElement(SOAPElement element) throws SOAPException {
if (!(element instanceof SOAPHeader)) {
log.severe("SAAJ0130.impl.header.elem.parent.mustbe.header");
throw new SOAPException("Parent of a SOAPHeaderElement has to be a SOAPHeader");
}
super.setParentElement(element);
}
+ @Override
public void setActor(String actorUri) {
try {
removeAttribute(getActorAttributeName());
addAttribute((Name) getActorAttributeName(), actorUri);
} catch (SOAPException ex) {
}
}
//SOAP 1.2 supports Role
+ @Override
public void setRole(String roleUri) throws SOAPException {
// runtime exception thrown if called for SOAP 1.1
removeAttribute(getRoleAttributeName());
addAttribute((Name) getRoleAttributeName(), roleUri);
}
Name actorAttNameWithoutNS = NameImpl.createFromTagName("actor");
+ @Override
public String getActor() {
String actor = getAttributeValue(getActorAttributeName());
return actor;
}
Name roleAttNameWithoutNS = NameImpl.createFromTagName("role");
+ @Override
public String getRole() {
// runtime exception thrown for 1.1
String role = getAttributeValue(getRoleAttributeName());
return role;
}
+ @Override
public void setMustUnderstand(boolean mustUnderstand) {
try {
removeAttribute(getMustunderstandAttributeName());
addAttribute(
(Name) getMustunderstandAttributeName(),
getMustunderstandLiteralValue(mustUnderstand));
} catch (SOAPException ex) {
}
}
+ @Override
public boolean getMustUnderstand() {
String mu = getAttributeValue(getMustunderstandAttributeName());
if (mu != null)
return getMustunderstandAttributeValue(mu);
return false;
}
+ @Override
public void setRelay(boolean relay) throws SOAPException {
// runtime exception thrown for 1.1
removeAttribute(getRelayAttributeName());
addAttribute(
(Name) getRelayAttributeName(),
getRelayLiteralValue(relay));
}
+ @Override
public boolean getRelay() {
String mu = getAttributeValue(getRelayAttributeName());
if (mu != null)
return getRelayAttributeValue(mu);
< prev index next >