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

com.swak.license.api.UncheckedLicenseManager Maven / Gradle / Ivy

The newest version!
/*
 * Copyright (C) 2005 - 2019 Schlichtherle IT Services.
 * All rights reserved. Use is subject to license terms.
 */
package com.swak.license.api;

import java.util.concurrent.Callable;

/**
 * Provides utilities for unchecked license managers.
 *
 * @see UncheckedConsumerLicenseManager
 * @see UncheckedVendorLicenseManager
 */
final class UncheckedLicenseManager {

    private UncheckedLicenseManager() {
    }

    static  V callUnchecked(Callable task) {
        try {
            return task.call();
        } catch (RuntimeException e) {
            throw e;
        } catch (Exception e) {
            throw new UncheckedLicenseManagementException(e);
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy