// #4 Use javax.xml.ws.Service
if (serviceImplClass == null)
serviceImplClass = Service.class.getName();
// #1 Use the explicit @WebServiceRef.type
if (wsref != null && wsref.type() != Object.class)
targetClassName = wsref.type().getName();
// #2 Use the target ref type
if (targetClassName == null && targetClass != null && Service.class.isAssignableFrom(targetClass) == false)
targetClassName = targetClass.getName();