AssertionDescriptionExtractor { public AssertionType getAssertion(Object obj) { try { if (obj != null) { if (obj instanceof AssertionType) { return (AssertionType) obj; } else { return getAssertionType(obj.getClass().getDeclaredMethods(), obj); } } } catch (IllegalAccessException | InvocationTargetException ex) { LOG.info("Unable to extract AssertionType from Object", ex); } return null; }  String getNPI(AssertionType assertion); String getInitiatingHCID(AssertionType assertion); AssertionType getAssertion(Object obj);  }
@Test public void extractAssertionFromRespondingGatewayPDRequestType() { AssertionDescriptionExtractor extractor = new AssertionDescriptionExtractor(); RespondingGatewayPRPAIN201305UV02RequestType request = new RespondingGatewayPRPAIN201305UV02RequestType(); AssertionType assertion = new AssertionType(); request.setAssertion(assertion); AssertionType returnAssertion = extractor.getAssertion((Object) request); assertNotNull(returnAssertion); }
@Test public void extractAssertionFromRespondingGatewayQDRequestType() { AssertionDescriptionExtractor extractor = new AssertionDescriptionExtractor(); RespondingGatewayCrossGatewayQueryRequestType request = new RespondingGatewayCrossGatewayQueryRequestType(); AssertionType assertion = new AssertionType(); request.setAssertion(assertion); AssertionType returnAssertion = extractor.getAssertion((Object) request); assertNotNull(returnAssertion); }
@Test public void extractAssertionFromRespondingGatewayRDRequestType() { AssertionDescriptionExtractor extractor = new AssertionDescriptionExtractor(); RespondingGatewayCrossGatewayRetrieveRequestType request = new RespondingGatewayCrossGatewayRetrieveRequestType(); AssertionType assertion = new AssertionType(); request.setAssertion(assertion); AssertionType returnAssertion = extractor.getAssertion((Object) request); assertNotNull(returnAssertion); }
@Test public void extractAssertionFromRespondingGatewayDSRequestType() { AssertionDescriptionExtractor extractor = new AssertionDescriptionExtractor(); RespondingGatewayProvideAndRegisterDocumentSetRequestType request = new RespondingGatewayProvideAndRegisterDocumentSetRequestType(); AssertionType assertion = new AssertionType(); request.setAssertion(assertion); AssertionType returnAssertion = extractor.getAssertion((Object) request); assertNotNull(returnAssertion); }
@Test public void extractAssertionFromRespondingGatewayDSDefResponseType() { AssertionDescriptionExtractor extractor = new AssertionDescriptionExtractor(); RespondingGatewayProvideAndRegisterDocumentSetResponseRequestType request = new RespondingGatewayProvideAndRegisterDocumentSetResponseRequestType(); AssertionType assertion = new AssertionType(); request.setAssertion(assertion); AssertionType returnAssertion = extractor.getAssertion((Object) request); assertNotNull(returnAssertion); }
@Test public void extractAssertionFromRespondingGatewayAD() { AssertionDescriptionExtractor extractor = new AssertionDescriptionExtractor(); RespondingGatewaySendAlertMessageType request = new RespondingGatewaySendAlertMessageType(); AssertionType assertion = new AssertionType(); request.setAssertion(assertion); AssertionType returnAssertion = extractor.getAssertion((Object) request); assertNotNull(returnAssertion); }
@Test public void extractAssertion() { AssertionDescriptionExtractor extractor = new AssertionDescriptionExtractor(); NhinTargetCommunitiesType target = new NhinTargetCommunitiesType(); AssertionType returnAssertion = extractor.getAssertion((Object) target); assertNull(returnAssertion); }
@Test public void extractAssertionNullObjet() { AssertionDescriptionExtractor extractor = new AssertionDescriptionExtractor(); AssertionType returnAssertion = extractor.getAssertion(null); assertNull(returnAssertion); }