TenantFunction

public abstract class TenantFunction<T> extends TenantAware implements Function<T, R>

A function which can work in single-tenant and multi-tenant context and return a value depending on the current tenant set.

Parameters

<T>

the type of the result returned by the function

Constructors

Link copied to clipboard
protected void TenantFunction(boolean multitenant)
Creates a new instance of the function.

Functions

Link copied to clipboard
public T execute()
Applies the function and returns the result.

Inherited functions

Link copied to clipboard
public Function<T, V> andThen<V>(Function<? extends Object, ? extends V> after)
Link copied to clipboard
public abstract R apply(T p)
Link copied to clipboard
public Function<V, R> compose<V>(Function<? extends Object, ? extends T> before)
Link copied to clipboard
public static Function<T, T> identity<T>()
Link copied to clipboard
public static boolean isTenantSet()
Verifies whether a current tenant is set in the execution context.