public class org.finos.legend.engine.shared.core.kerberos.ProfileManagerHelper extends java.lang.Object
{
public void <init>()
{
org.finos.legend.engine.shared.core.kerberos.ProfileManagerHelper v;
v := @this: org.finos.legend.engine.shared.core.kerberos.ProfileManagerHelper;
specialinvoke v.<java.lang.Object: void <init>()>();
return;
}
public static javax.security.auth.Subject extractSubject(org.pac4j.core.profile.ProfileManager)
{
java.util.List v;
org.pac4j.core.profile.ProfileManager v;
javax.security.auth.Subject v;
v := @parameter: org.pac4j.core.profile.ProfileManager;
if v != null goto label;
v = null;
goto label;
label:
v = virtualinvoke v.<org.pac4j.core.profile.ProfileManager: java.util.List getAll(boolean)>(1);
v = staticinvoke <org.finos.legend.engine.shared.core.kerberos.ProfileManagerHelper: javax.security.auth.Subject extractSubject(java.lang.Iterable)>(v);
label:
return v;
}
public static javax.security.auth.Subject extractSubject(java.lang.Iterable)
{
org.eclipse.collections.api.LazyIterable v, v, v;
org.eclipse.collections.api.block.function.Function v;
org.eclipse.collections.api.block.predicate.Predicate v;
java.lang.Object v;
java.lang.Iterable v;
v := @parameter: java.lang.Iterable;
if v != null goto label;
return null;
label:
v = staticinvoke <org.eclipse.collections.impl.utility.LazyIterate: org.eclipse.collections.api.LazyIterable selectInstancesOf(java.lang.Iterable,java.lang.Class)>(v, class "Lorg/finos/legend/server/pac4j/kerberos/KerberosProfile;");
v = staticinvoke <org.finos.legend.engine.shared.core.kerberos.ProfileManagerHelper$getSubject__1: org.eclipse.collections.api.block.function.Function bootstrap$()>();
v = interfaceinvoke v.<org.eclipse.collections.api.LazyIterable: org.eclipse.collections.api.LazyIterable collect(org.eclipse.collections.api.block.function.Function)>(v);
v = staticinvoke <org.finos.legend.engine.shared.core.kerberos.ProfileManagerHelper$nonNull__2: org.eclipse.collections.api.block.predicate.Predicate bootstrap$()>();
v = interfaceinvoke v.<org.eclipse.collections.api.LazyIterable: org.eclipse.collections.api.LazyIterable select(org.eclipse.collections.api.block.predicate.Predicate)>(v);
v = interfaceinvoke v.<org.eclipse.collections.api.LazyIterable: java.lang.Object getFirst()>();
return v;
}
public static org.eclipse.collections.api.list.MutableList extractProfiles(org.pac4j.core.profile.ProfileManager)
{
org.pac4j.core.profile.ProfileManager v;
java.util.Optional v;
java.lang.Object v;
org.eclipse.collections.api.list.FixedSizeList v, v;
org.eclipse.collections.api.factory.list.FixedSizeListFactory v, v;
boolean v;
v := @parameter: org.pac4j.core.profile.ProfileManager;
if v == null goto label;
v = virtualinvoke v.<org.pac4j.core.profile.ProfileManager: java.util.Optional get(boolean)>(1);
v = virtualinvoke v.<java.util.Optional: boolean isPresent()>();
if v == 0 goto label;
v = <org.eclipse.collections.api.factory.Lists: org.eclipse.collections.api.factory.list.FixedSizeListFactory fixedSize>;
v = virtualinvoke v.<java.util.Optional: java.lang.Object get()>();
v = interfaceinvoke v.<org.eclipse.collections.api.factory.list.FixedSizeListFactory: org.eclipse.collections.api.list.FixedSizeList 'with'(java.lang.Object)>(v);
return v;
label:
v = <org.eclipse.collections.api.factory.Lists: org.eclipse.collections.api.factory.list.FixedSizeListFactory fixedSize>;
v = interfaceinvoke v.<org.eclipse.collections.api.factory.list.FixedSizeListFactory: org.eclipse.collections.api.list.FixedSizeList empty()>();
return v;
}
}