public class io.smallrye.context.SmallRyeContextManagerProvider extends java.lang.Object implements org.eclipse.microprofile.context.spi.ContextManagerProvider
{
private static org.eclipse.microprofile.context.spi.ContextManagerProviderRegistration registration;
private java.util.Map contextManagersForClassLoader;
public void <init>()
{
java.util.HashMap v;
io.smallrye.context.SmallRyeContextManagerProvider v;
v := @this: io.smallrye.context.SmallRyeContextManagerProvider;
specialinvoke v.<java.lang.Object: void <init>()>();
v = new java.util.HashMap;
specialinvoke v.<java.util.HashMap: void <init>()>();
v.<io.smallrye.context.SmallRyeContextManagerProvider: java.util.Map contextManagersForClassLoader> = v;
return;
}
public static void register()
{
org.eclipse.microprofile.context.spi.ContextManagerProviderRegistration v, v;
io.smallrye.context.SmallRyeContextManagerProvider v;
v = <io.smallrye.context.SmallRyeContextManagerProvider: org.eclipse.microprofile.context.spi.ContextManagerProviderRegistration registration>;
if v != null goto label;
v = new io.smallrye.context.SmallRyeContextManagerProvider;
specialinvoke v.<io.smallrye.context.SmallRyeContextManagerProvider: void <init>()>();
v = staticinvoke <org.eclipse.microprofile.context.spi.ContextManagerProvider: org.eclipse.microprofile.context.spi.ContextManagerProviderRegistration register(org.eclipse.microprofile.context.spi.ContextManagerProvider)>(v);
<io.smallrye.context.SmallRyeContextManagerProvider: org.eclipse.microprofile.context.spi.ContextManagerProviderRegistration registration> = v;
label:
return;
}
public static void unregister()
{
org.eclipse.microprofile.context.spi.ContextManagerProviderRegistration v;
v = <io.smallrye.context.SmallRyeContextManagerProvider: org.eclipse.microprofile.context.spi.ContextManagerProviderRegistration registration>;
virtualinvoke v.<org.eclipse.microprofile.context.spi.ContextManagerProviderRegistration: void unregister()>();
<io.smallrye.context.SmallRyeContextManagerProvider: org.eclipse.microprofile.context.spi.ContextManagerProviderRegistration registration> = null;
return;
}
public io.smallrye.context.SmallRyeContextManager getContextManager()
{
io.smallrye.context.SmallRyeContextManagerProvider v;
java.lang.Thread v;
io.smallrye.context.SmallRyeContextManager v;
java.lang.ClassLoader v;
v := @this: io.smallrye.context.SmallRyeContextManagerProvider;
v = staticinvoke <java.lang.Thread: java.lang.Thread currentThread()>();
v = virtualinvoke v.<java.lang.Thread: java.lang.ClassLoader getContextClassLoader()>();
v = virtualinvoke v.<io.smallrye.context.SmallRyeContextManagerProvider: io.smallrye.context.SmallRyeContextManager getContextManager(java.lang.ClassLoader)>(v);
return v;
}
public io.smallrye.context.SmallRyeContextManager getContextManager(java.lang.ClassLoader)
{
io.smallrye.context.SmallRyeContextManager$Builder v, v, v, v, v;
java.lang.Throwable v;
io.smallrye.context.SmallRyeContextManagerProvider v;
java.util.Map v, v;
java.lang.Object v;
java.lang.ClassLoader v;
v := @this: io.smallrye.context.SmallRyeContextManagerProvider;
v := @parameter: java.lang.ClassLoader;
v = v.<io.smallrye.context.SmallRyeContextManagerProvider: java.util.Map contextManagersForClassLoader>;
v = interfaceinvoke v.<java.util.Map: java.lang.Object get(java.lang.Object)>(v);
if v != null goto label;
entermonitor v;
label:
v = v.<io.smallrye.context.SmallRyeContextManagerProvider: java.util.Map contextManagersForClassLoader>;
interfaceinvoke v.<java.util.Map: java.lang.Object get(java.lang.Object)>(v);
v = virtualinvoke v.<io.smallrye.context.SmallRyeContextManagerProvider: io.smallrye.context.SmallRyeContextManager$Builder getContextManagerBuilder()>();
v = virtualinvoke v.<io.smallrye.context.SmallRyeContextManager$Builder: io.smallrye.context.SmallRyeContextManager$Builder forClassLoader(java.lang.ClassLoader)>(v);
v = virtualinvoke v.<io.smallrye.context.SmallRyeContextManager$Builder: io.smallrye.context.SmallRyeContextManager$Builder registerOnProvider()>();
v = virtualinvoke v.<io.smallrye.context.SmallRyeContextManager$Builder: io.smallrye.context.SmallRyeContextManager$Builder addDiscoveredThreadContextProviders()>();
v = virtualinvoke v.<io.smallrye.context.SmallRyeContextManager$Builder: io.smallrye.context.SmallRyeContextManager$Builder addDiscoveredContextManagerExtensions()>();
v = virtualinvoke v.<io.smallrye.context.SmallRyeContextManager$Builder: io.smallrye.context.SmallRyeContextManager build()>();
exitmonitor v;
label:
goto label;
label:
v := @caughtexception;
exitmonitor v;
throw v;
label:
return v;
catch java.lang.Throwable from label to label with label;
}
public io.smallrye.context.SmallRyeContextManager$Builder getContextManagerBuilder()
{
io.smallrye.context.SmallRyeContextManager$Builder v;
io.smallrye.context.SmallRyeContextManagerProvider v;
v := @this: io.smallrye.context.SmallRyeContextManagerProvider;
v = new io.smallrye.context.SmallRyeContextManager$Builder;
specialinvoke v.<io.smallrye.context.SmallRyeContextManager$Builder: void <init>()>();
return v;
}
public void registerContextManager(org.eclipse.microprofile.context.spi.ContextManager, java.lang.ClassLoader)
{
java.lang.Throwable v;
io.smallrye.context.SmallRyeContextManagerProvider v;
java.lang.IllegalArgumentException v;
org.eclipse.microprofile.context.spi.ContextManager v;
java.util.Map v;
java.lang.ClassLoader v;
java.lang.String v;
boolean v;
v := @this: io.smallrye.context.SmallRyeContextManagerProvider;
v := @parameter: org.eclipse.microprofile.context.spi.ContextManager;
v := @parameter: java.lang.ClassLoader;
v = v instanceof io.smallrye.context.SmallRyeContextManager;
if v != 0 goto label;
v = new java.lang.IllegalArgumentException;
v = dynamicinvoke "makeConcatWithConstants" <java.lang.String (org.eclipse.microprofile.context.spi.ContextManager)>(v) <java.lang.invoke.StringConcatFactory: java.lang.invoke.CallSite makeConcatWithConstants(java.lang.invoke.MethodHandles$Lookup,java.lang.String,java.lang.invoke.MethodType,java.lang.String,java.lang.Object[])>("Only instances of SmallRyeContextManager are supported: \u0001");
specialinvoke v.<java.lang.IllegalArgumentException: void <init>(java.lang.String)>(v);
throw v;
label:
entermonitor v;
label:
v = v.<io.smallrye.context.SmallRyeContextManagerProvider: java.util.Map contextManagersForClassLoader>;
interfaceinvoke v.<java.util.Map: java.lang.Object put(java.lang.Object,java.lang.Object)>(v, v);
exitmonitor v;
label:
goto label;
label:
v := @caughtexception;
exitmonitor v;
throw v;
label:
return;
catch java.lang.Throwable from label to label with label;
}
public void releaseContextManager(org.eclipse.microprofile.context.spi.ContextManager)
{
java.lang.Throwable v;
java.util.Iterator v;
io.smallrye.context.SmallRyeContextManagerProvider v;
java.util.Set v;
org.eclipse.microprofile.context.spi.ContextManager v;
java.util.Map v;
java.lang.Object v, v;
boolean v;
v := @this: io.smallrye.context.SmallRyeContextManagerProvider;
v := @parameter: org.eclipse.microprofile.context.spi.ContextManager;
entermonitor v;
label:
v = v.<io.smallrye.context.SmallRyeContextManagerProvider: java.util.Map contextManagersForClassLoader>;
v = interfaceinvoke v.<java.util.Map: java.util.Set entrySet()>();
v = interfaceinvoke v.<java.util.Set: java.util.Iterator iterator()>();
label:
v = interfaceinvoke v.<java.util.Iterator: boolean hasNext()>();
if v == 0 goto label;
v = interfaceinvoke v.<java.util.Iterator: java.lang.Object next()>();
v = interfaceinvoke v.<java.util.Map$Entry: java.lang.Object getValue()>();
if v != v goto label;
interfaceinvoke v.<java.util.Iterator: void remove()>();
exitmonitor v;
label:
return;
label:
exitmonitor v;
label:
goto label;
label:
v := @caughtexception;
exitmonitor v;
throw v;
label:
return;
catch java.lang.Throwable from label to label with label;
catch java.lang.Throwable from label to label with label;
}
public org.eclipse.microprofile.context.spi.ContextManager findContextManager(java.lang.ClassLoader)
{
io.smallrye.context.SmallRyeContextManagerProvider v;
java.util.Map v;
java.lang.Object v;
java.lang.ClassLoader v;
v := @this: io.smallrye.context.SmallRyeContextManagerProvider;
v := @parameter: java.lang.ClassLoader;
v = v.<io.smallrye.context.SmallRyeContextManagerProvider: java.util.Map contextManagersForClassLoader>;
v = interfaceinvoke v.<java.util.Map: java.lang.Object get(java.lang.Object)>(v);
return v;
}
public static io.smallrye.context.SmallRyeContextManager getManager()
{
io.smallrye.context.SmallRyeContextManager v;
io.smallrye.context.SmallRyeContextManagerProvider v;
v = staticinvoke <io.smallrye.context.SmallRyeContextManagerProvider: io.smallrye.context.SmallRyeContextManagerProvider instance()>();
v = virtualinvoke v.<io.smallrye.context.SmallRyeContextManagerProvider: io.smallrye.context.SmallRyeContextManager getContextManager()>();
return v;
}
public static io.smallrye.context.SmallRyeContextManagerProvider instance()
{
org.eclipse.microprofile.context.spi.ContextManagerProvider v;
v = staticinvoke <org.eclipse.microprofile.context.spi.ContextManagerProvider: org.eclipse.microprofile.context.spi.ContextManagerProvider instance()>();
return v;
}
}