Package org.eclipse.microprofile.fault.tolerance.tck.metrics.common

# Class FallbackMetricBean

java.lang.Object
org.eclipse.microprofile.fault.tolerance.tck.metrics.common.FallbackMetricBean

@ApplicationScoped public class FallbackMetricBean extends Object

## Nested Class Summary

Nested Classes
Modifier and Type
Class
Description
`static enum`
`FallbackMetricBean.Action`
`static class`
`FallbackMetricBean.NonFallbackException`

## Constructor Summary

Constructors
Constructor
Description
`FallbackMetricBean()`

## Method Summary

Modifier and Type
Method
Description
`void`
`doFallback(FallbackMetricBean.Action action)`
`void`
`doWork(FallbackMetricBean.Action action)`
`Void`
`doWorkWithHandler(FallbackMetricBean.Action action)`
`FallbackMetricBean.Action`
`getFallbackAction()`
Get whether the fallback method and handler should pass or throw an exception
`void`
`setFallbackAction(FallbackMetricBean.Action action)`
Set whether the fallback method and handler should pass or throw an exception

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Constructor Details

### FallbackMetricBean

public FallbackMetricBean()

## Method Details

### doWork

@Fallback(fallbackMethod="doFallback", skipOn=NonFallbackException.class) public void doWork(FallbackMetricBean.Action action)

### doFallback

public void doFallback(FallbackMetricBean.Action action)

### doWorkWithHandler

@Fallback(value=FallbackMetricHandler.class, applyOn=TestException.class) public Void doWorkWithHandler(FallbackMetricBean.Action action)

### setFallbackAction

public void setFallbackAction(FallbackMetricBean.Action action)
Set whether the fallback method and handler should pass or throw an exception

Parameters:
  `action` - set to `FallbackMetricBean.Action` PASS or FAIL

### getFallbackAction

public FallbackMetricBean.Action getFallbackAction()
Get whether the fallback method and handler should pass or throw an exception

Returns:
  `FallbackMetricBean.Action` PASS or FAIL