// 
// Decompiled by Procyon v0.6.0
// 

package com.hypixel.hytale.server.core.auth;

import javax.annotation.Nonnull;
import java.time.Instant;
import javax.annotation.Nullable;
import java.util.UUID;

public class DefaultAuthCredentialStore implements IAuthCredentialStore
{
    private OAuthTokens tokens;
    @Nullable
    private UUID profile;
    
    public DefaultAuthCredentialStore() {
        this.tokens = new OAuthTokens(null, null, null);
    }
    
    @Override
    public void setTokens(@Nonnull final OAuthTokens tokens) {
        this.tokens = tokens;
    }
    
    @Nonnull
    @Override
    public OAuthTokens getTokens() {
        return this.tokens;
    }
    
    @Override
    public void setProfile(@Nullable final UUID uuid) {
        this.profile = uuid;
    }
    
    @Nullable
    @Override
    public UUID getProfile() {
        return this.profile;
    }
    
    @Override
    public void clear() {
        this.tokens = new OAuthTokens(null, null, null);
        this.profile = null;
    }
}
