Class Metered


  • public class Metered
    extends Object
    Starts a Meter with the given name, then invokes the callback, then finally stops the meter before returning the output.
    • Method Detail

      • meter

        public static <T> T meter​(String meterName,
                                  Metered.MeterCallbackWithOutput<T> callback)
                           throws sailpoint.tools.GeneralException
        Meters the invocation of the callback, including an output
        Type Parameters:
        T - The output type
        Parameters:
        meterName - The meter name
        callback - The callback to invoke
        Returns:
        The output of the callback
        Throws:
        sailpoint.tools.GeneralException - on any errors in the callback
      • meter

        public static void meter​(String meterName,
                                 Metered.MeterCallback callback)
                          throws sailpoint.tools.GeneralException
        Meters the invocation of the callback, without an output
        Parameters:
        meterName - The meter name
        callback - The callback to invoke
        Throws:
        sailpoint.tools.GeneralException - on any errors in the callback