* where the message label property IS NOT present in the binding fault reference.
*
*/
public InterfaceFaultReference getInterfaceFaultReference()
{
InterfaceFaultReference intFaultRef = null;
if(fRef != null) //if 'ref' is null, we cannot match against an interface fault qname.
{
BindingOperation bindOp = (BindingOperation)getParent();
InterfaceOperation intOp = bindOp.getInterfaceOperation();
if(intOp != null)
{
//Determine the "effective" msg label for this binding fault ref.
NCName effectiveMsgLabel = null;
if(fMessageLabel != null)
{
effectiveMsgLabel = fMessageLabel;
}
else
{
//implement placeholder effective msg label, as per the todo comment above
}
//Now match the effective msg label against the msg label of an interface fault reference
//that refers to an interface fault whose qname matches the 'ref' attribute.
if(effectiveMsgLabel != null)
{
InterfaceFaultReference[] intFaultRefs = intOp.getInterfaceFaultReferences();
for(int i=0; i<intFaultRefs.length; i++)
{
InterfaceFaultReference tempIntFaultRef = intFaultRefs[i];
InterfaceFault tempIntFault = tempIntFaultRef.getInterfaceFault();
QName intFaultName = (tempIntFault != null ? tempIntFault.getName() : null);
if(fRef.equals(intFaultName) &&
effectiveMsgLabel.equals(tempIntFaultRef.getMessageLabel()))
{
intFaultRef = tempIntFaultRef;
break;
}
}