<commit_before>package com.firebase.security.token;

import java.util.Date;

/**
 * Token options.
 *
 * @author vikrum
 */
public class TokenOptions {

    private Date expires;
    private Date notBefore;
    private boolean admin;
    private boolean debug;

    /**
     * Default constructor.
     */
    public TokenOptions() {
        expires = null;
        notBefore = null;
        admin = false;
        debug = false;
    }

    /**
     * Parametrized constructor.
     *
     * @param expires   The date/time at which the token should no longer be considered valid. (default is never).
     * @param notBefore The date/time before which the token should not be considered valid. (default is now).
     * @param admin     Set to true to bypass all security rules (you can use this for trusted server code).
     * @param debug     Set to true to enable debug mode (so you can see the results of Rules API operations).
     */
    public TokenOptions(Date expires, Date notBefore, boolean admin, boolean debug) {
        super();
        this.expires = expires;
        this.notBefore = notBefore;
        this.admin = admin;
        this.debug = debug;
    }

    /**
     * @return the expires
     */
    public Date getExpires() {
        return expires;
    }

    /**
     * @param expires the expires to set
     */
    public void setExpires(Date expires) {
        this.expires = expires;
    }

    /**
     * @return the notBefore
     */
    public Date getNotBefore() {
        return notBefore;
    }

    /**
     * @param notBefore the notBefore to set
     */
    public void setNotBefore(Date notBefore) {
        this.notBefore = notBefore;
    }

    /**
     * @return the admin
     */
    public boolean isAdmin() {
        return admin;
    }
<commit_msg>defensive copy of dates in TokenOptions<commit_after>package com.firebase.security.token;

import java.util.Date;

/**
 * Token options.
 *
 * @author vikrum
 */
public class TokenOptions {

    private Date expires;
    private Date notBefore;
    private boolean admin;
    private boolean debug;

    /**
     * Default constructor.
     */
    public TokenOptions() {
        expires = null;
        notBefore = null;
        admin = false;
        debug = false;
    }

    /**
     * Parametrized constructor.
     *
     * @param expires   The date/time at which the token should no longer be considered valid. (default is never).
     * @param notBefore The date/time before which the token should not be considered valid. (default is now).
     * @param admin     Set to true to bypass all security rules (you can use this for trusted server code).
     * @param debug     Set to true to enable debug mode (so you can see the results of Rules API operations).
     */
    public TokenOptions(Date expires, Date notBefore, boolean admin, boolean debug) {
        super();
        this.expires = (expires != null) ? new Date(expires.getTime()) : null;
        this.notBefore = (notBefore != null) ? new Date(notBefore.getTime()) : null;
        this.admin = admin;
        this.debug = debug;
    }

    /**
     * @return the expires
     */
    public Date getExpires() {
        return expires;
    }

    /**
     * @param expires the expires to set
     */
    public void setExpires(Date expires) {
        this.expires = (expires != null) ? new Date(expires.getTime()) : null;
    }

    /**
     * @return the notBefore
     */
    public Date getNotBefore() {
        return notBefore;
    }

    /**
     * @param notBefore the notBefore to set
     */
    public void setNotBefore(Date notBefore) {
        this.notBefore = (notBefore != null) ? new Date(notBefore.getTime()) : null;
    }

    /**
     * @return the admin
     */
    public boolean isAdmin() {
        return admin;
    }

{'fraction_non_alphanumeric': 0.0968421052631579, 'fraction_numerical': 0.0, 'mean_word_length': 2.080226904376013, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4330929', 'n_tokens_mistral': 1080, 'n_tokens_neox': 1043, 'n_words': 367}