/*
 * Decompiled with CFR 0.152.
 * 
 * Could not load the following classes:
 *  com.l7tech.message.Message
 *  com.l7tech.policy.variable.Syntax$SyntaxErrorHandler
 */
package com.l7tech.server.policy.variable;

import com.l7tech.message.Message;
import com.l7tech.policy.variable.Syntax;
import com.l7tech.server.message.PolicyEnforcementContext;
import com.l7tech.server.message.PolicyEnforcementContextFactory;
import com.l7tech.server.policy.variable.ExpandVariables;
import com.l7tech.server.policy.variable.MessageSelector;
import com.l7tech.server.policy.variable.bh;

class ex
implements MessageSelector.MessageAttributeSelector {
    final bh val$authenticatedUserGetter;

    /*
     * Ignored method signature, as it can't be verified against descriptor
     */
    ex(MessageSelector messageSelector, bh bh2) {
        this.val$authenticatedUserGetter = bh2;
    }

    @Override
    public ExpandVariables.Selector.Selection select(Message message, String string, Syntax.SyntaxErrorHandler syntaxErrorHandler, boolean bl2) {
        PolicyEnforcementContext policyEnforcementContext = PolicyEnforcementContextFactory.getCurrent();
        Object object = policyEnforcementContext == null ? null : this.val$authenticatedUserGetter.get(string, policyEnforcementContext);
        return object == null ? null : new ExpandVariables.Selector.Selection(object);
    }
}

