package com.atlassian.bitbucket.internal.scm.git.lfs.dao;

import net.java.ao.Accessor;
import net.java.ao.Mutator;
import net.java.ao.Preload;
import net.java.ao.RawEntity;
import net.java.ao.schema.NotNull;
import net.java.ao.schema.PrimaryKey;
import net.java.ao.schema.Table;

/**
 * Active Object hosting per repository data for Git LFS
 */
@Preload
@Table("GIT_LFS_REPO_CONFIG")
public interface AoGitLfsRepositoryConfig extends RawEntity<Integer> {

    String ENABLED_COLUMN = "IS_ENABLED";
    String REPOSITORY_ID_COLUMN = "REPOSITORY_ID";

    @NotNull
    @PrimaryKey(REPOSITORY_ID_COLUMN)
    int getRepositoryId();

    @NotNull
    @Accessor(ENABLED_COLUMN)
    boolean isEnabled();

    @Mutator(ENABLED_COLUMN)
    void setEnabled(boolean enabled);
}
