public static String infoPledgepaymentContribution(Logger logger, Connection connection, Pledgepayment pledgepayment, Contribution contribution, Enum_status status) {
        String entity;
        String message_contribution = "";
        String receivedate;
        try {
            SimpleDateFormat simpledateformat = new SimpleDateFormat("dd-MM-yyyy");
            if (contribution != null) {
                // Format contribution amount
                String amount;
                amount = String.format("%8.2f", contribution.getTotal_amount());

                if (contribution.getReceive_date() != null) {
                    receivedate = simpledateformat.format(pledgepayment.getScheduled_date());
                } else {
                    receivedate = String.format("%-10s", "NULL");
                }
                entity = String.format("%7s", contribution.getId());
                entity = entity.concat(" ").concat(String.format("%-9s", "CONTRIBUT"));
                message_contribution = entity.concat(amount).concat(" on ").concat(receivedate);
            }
            switch (status) {
                case COMPLETED:
                    return message_contribution;
                case PENDING:
                    return "payment is not due yet";
                case CANCELLED:
                    // Pledgepayments can only be cancelled manually
                    return "";
                case FAILED:
                    // Failed status currently not supported by this module
                    return "";
                case INPROGRESS:
                    return "payment expected later this period";
                case OVERDUE:
                    return "payment expected, but none found";
                default:
                    return "ERROR: Unsupported status";
            }
        } catch (Exception e) {
            java.util.logging.Logger.getLogger(CivicrmLogger.class.getName()).log(Level.SEVERE, null, e);
            return "";
        }
    }