/*
 * Created on 3. 12. 2018 14:09:52
 *
 */
package com.jh.radegast.security;

import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;

import com.jh.common.jpa.AbstractIdEntity;

@Entity
@Table(name = "PASSWORD_RESET_REQUEST")
public class PasswordResetRequest extends AbstractIdEntity {
    
    private static final long serialVersionUID = 1L;

    @Column(name = "USER_ID")
    private Long userId;
    
    @Column(name = "CREATED")
    private Date created;
    
    @Column(name = "VALID_UNTIL")
    private Date validUntil;
    
    @Column(name = "HASH")
    private String hash;
    
    @Column(name = "ADDRESS")
    private String ipAddress;

    public PasswordResetRequest() {
        super();
    }

    public PasswordResetRequest(Long userId, Date created, Date validUntil, String hash, String ipAddress) {
        super();
        this.userId = userId;
        this.created = created;
        this.validUntil = validUntil;
        this.hash = hash;
        this.ipAddress = ipAddress;
    }

    public Long getUserId() {
        return userId;
    }

    public void setUserId(Long userId) {
        this.userId = userId;
    }

    public Date getCreated() {
        return created;
    }

    public void setCreated(Date created) {
        this.created = created;
    }

    public Date getValidUntil() {
        return validUntil;
    }

    public void setValidUntil(Date validUntil) {
        this.validUntil = validUntil;
    }

    public String getHash() {
        return hash;
    }

    public void setHash(String hash) {
        this.hash = hash;
    }

    public String getIpAddress() {
        return ipAddress;
    }

    public void setIpAddress(String ipAddress) {
        this.ipAddress = ipAddress;
    }

    
    
}
