All Downloads are FREE. Search and download functionalities are using the official Maven repository.

no.digipost.xsd.types.HarVarsler Maven / Gradle / Ivy

package no.digipost.xsd.types;

import no.difi.begrep.sdp.schema_v10.SDPEpostVarsel;
import no.difi.begrep.sdp.schema_v10.SDPSmsVarsel;
import no.difi.begrep.sdp.schema_v10.SDPVarsler;

import java.util.Optional;

public interface HarVarsler {

    SDPVarsler getVarsler();

    default Optional getSmsVarsel() {
        return Optional.ofNullable(getVarsler()).map(SDPVarsler::getSmsVarsel);
    }

    default Optional getEpostVarsel() {
        return Optional.ofNullable(getVarsler()).map(SDPVarsler::getEpostVarsel);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy