Status.java

/*
 * Copyright © 2012-2025 The CTAN Team and individual authors
 *
 * This file is distributed under the 3-clause BSD license.
 * See file LICENSE for details.
 */
package org.ctan.site.domain.mirrors;

import jakarta.persistence.Column;
import jakarta.persistence.Entity;
import jakarta.persistence.GeneratedValue;
import jakarta.persistence.Id;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Getter;
import lombok.NoArgsConstructor;

/**
 * This domain class represents the status of a CTAN mirror.
 *
 * @author <a href="mailto:gene@ctan.org">Gerd Neugebauer</a>
 */
@Entity
@Builder
@Getter
@NoArgsConstructor
@AllArgsConstructor
public class Status {

    /**
     * The field <code>id</code> contains the id.
     */
    @Id
    @GeneratedValue
    private Long id;

    /**
     * The field <code>description</code> contains the description in English.
     */
    @Column(length = 255, nullable = false)
    private String description;

    /**
     * {@inheritDoc}
     *
     * @see java.lang.Object#toString()
     */
    @Override
    public String toString() {

        return description;
    }
}