class PisCommonPaymentData extends InstanceDependableEntity implements Authorisable {

    @Override
    public String getInternalRequestId(AuthorisationType authorisationType) {
        if (authorisationType == AuthorisationType.PIS_CREATION) {
            return internalRequestId;
        } else if (authorisationType == AuthorisationType.PIS_CANCELLATION) {
            return cancellationInternalRequestId;
        }

        throw new IllegalArgumentException("Invalid authorisation type: " + authorisationType);
    }

}