Search in sources :

Example 11 with PdlLogMessage

use of se.inera.intyg.infra.logmessages.PdlLogMessage in project webcert by sklintyg.

the class IntygReadMessage method build.

public static PdlLogMessage build(String intygId) {
    PdlLogMessage pdlLogMessage = new PdlLogMessage(ActivityType.READ);
    pdlLogMessage.setActivityLevel(intygId);
    return pdlLogMessage;
}
Also used : PdlLogMessage(se.inera.intyg.infra.logmessages.PdlLogMessage)

Example 12 with PdlLogMessage

use of se.inera.intyg.infra.logmessages.PdlLogMessage in project webcert by sklintyg.

the class IntygSendMessage method build.

public static PdlLogMessage build(String intygId, String additionalInfo) {
    PdlLogMessage pdlLogMessage = new PdlLogMessage(ActivityType.SEND);
    pdlLogMessage.setActivityLevel(intygId);
    pdlLogMessage.setActivityArgs(additionalInfo);
    return pdlLogMessage;
}
Also used : PdlLogMessage(se.inera.intyg.infra.logmessages.PdlLogMessage)

Example 13 with PdlLogMessage

use of se.inera.intyg.infra.logmessages.PdlLogMessage in project webcert by sklintyg.

the class IntygUpdateMessage method build.

public static PdlLogMessage build(String intygId) {
    PdlLogMessage pdlLogMessage = new PdlLogMessage(ActivityType.UPDATE);
    pdlLogMessage.setActivityLevel(intygId);
    return pdlLogMessage;
}
Also used : PdlLogMessage(se.inera.intyg.infra.logmessages.PdlLogMessage)

Example 14 with PdlLogMessage

use of se.inera.intyg.infra.logmessages.PdlLogMessage in project webcert by sklintyg.

the class LogMessagePopulatorImplTest method testActivityArgsAddedFromAdditionalInfoWhenActivityArgsAbsent.

@Test
public void testActivityArgsAddedFromAdditionalInfoWhenActivityArgsAbsent() {
    PdlLogMessage logMessage = testee.populateLogMessage(buildLogRequest(ADDITIONAL_INFO), buildPdlLogMessage(""), buildLogUser());
    assertEquals(ADDITIONAL_INFO, logMessage.getActivityArgs());
}
Also used : PdlLogMessage(se.inera.intyg.infra.logmessages.PdlLogMessage) Test(org.junit.Test)

Example 15 with PdlLogMessage

use of se.inera.intyg.infra.logmessages.PdlLogMessage in project webcert by sklintyg.

the class LogMessagePopulatorImplTest method testActivityArgsUntouchedWhenActivityArgsExistsButNoAdditionalInfo.

@Test
public void testActivityArgsUntouchedWhenActivityArgsExistsButNoAdditionalInfo() {
    PdlLogMessage logMessage = testee.populateLogMessage(buildLogRequest(""), buildPdlLogMessage(ACTIVITY_ARGS), buildLogUser());
    assertEquals(ACTIVITY_ARGS, logMessage.getActivityArgs());
}
Also used : PdlLogMessage(se.inera.intyg.infra.logmessages.PdlLogMessage) Test(org.junit.Test)

Aggregations

PdlLogMessage (se.inera.intyg.infra.logmessages.PdlLogMessage)16 Test (org.junit.Test)5 IOException (java.io.IOException)1 Session (javax.jms.Session)1 MessageCreator (org.springframework.jms.core.MessageCreator)1 LogRequest (se.inera.intyg.webcert.web.service.log.dto.LogRequest)1