package com.l7tech.message;

import com.l7tech.policy.assertion.credential.LoginCredentials;
import com.l7tech.util.Disposable;
import com.l7tech.util.ResourceUtils;
import java.util.ArrayList;
import java.util.List;

public class CredentialContext implements Disposable {
   private final List<LoginCredentials> a = new ArrayList<>();
   private LoginCredentials b;
   private boolean c = false;

   public LoginCredentials getLastCredentials() {
      return this.b;
   }

   public List<LoginCredentials> getCredentials() {
      return this.a;
   }

   public void addCredentials(LoginCredentials var1) {
      this.a.add(var1);
      this.b = var1;
   }

   public boolean isAuthenticationMissing() {
      return this.c;
   }

   public void setAuthenticationMissing() {
      this.c = true;
   }

   public void dispose() {
      ResourceUtils.dispose(this.a);
   }
}
