<commit_before>/*
 * oxAuth is available under the MIT License (2008). See http://opensource.org/licenses/MIT for full text.
 *
 * Copyright (c) 2014, Gluu
 */

package org.oxauth.persistence.model;

import org.gluu.oxauth.model.common.ScopeType;
import org.gluu.persist.annotation.AttributeName;
import org.gluu.persist.annotation.DN;
import org.gluu.persist.annotation.DataEntry;
import org.gluu.persist.annotation.ObjectClass;

import java.io.Serializable;
import java.util.List;

/**
 * @author <NAME> Date: 07.05.2012
 * @author <NAME> Date: 06/30/2015
 */
@DataEntry
@ObjectClass(values = {"top", "oxAuthCustomScope"})
public class Scope implements Serializable {

    private static final long serialVersionUID = 4308826784917052508L;

    @DN
    private String dn;
    @AttributeName(ignoreDuringUpdate = true)
    private String inum;

    @AttributeName
    private String displayName;

    @AttributeName(name = "oxId")
    private String id;

    @AttributeName(name = "oxIconUrl")
    private String iconUrl;

    @AttributeName
    private String description;

    @AttributeName(name = "oxScopeType")
    private ScopeType scopeType;
 
    @AttributeName(name = "oxAuthClaim")
    private List<String> oxAuthClaims;

    @AttributeName(name = "defaultScope")
    private Boolean defaultScope;

    @AttributeName(name = "oxAuthGroupClaims")
    private Boolean oxAuthGroupClaims;

    @AttributeName(name = "oxScriptDn")
    private List<String> dynamicScopeScripts;

    @AttributeName(name = "oxUmaPolicyScriptDn")
    private List<String> umaAuthorizationPolicies;

    public String getDn() {
        return dn;
    }

    public void setDn(String dn) {
        this.dn = dn;
    }

    public String getInum() {
        return this.inum;
    }

    public void setInum(String inum) {
        this.inum = inum;
    }

    public String getDisplayName() {
        return this.displayName;
    }

    public void setDisplayName(String displayName) {
        this.displayName = displayName;
    }

    public String getDescription() {
        return this.description;
    }

    public void setDescription(String description) {<commit_msg>Enhance scope class<commit_after>/*
 * oxAuth is available under the MIT License (2008). See http://opensource.org/licenses/MIT for full text.
 *
 * Copyright (c) 2014, Gluu
 */

package org.oxauth.persistence.model;

import org.gluu.oxauth.model.common.ScopeType;
import org.gluu.persist.annotation.AttributeName;
import org.gluu.persist.annotation.DN;
import org.gluu.persist.annotation.DataEntry;
import org.gluu.persist.annotation.ObjectClass;

import java.io.Serializable;
import java.util.List;

/**
 * @author <NAME> Date: 07.05.2012
 * @author <NAME> Date: 06/30/2015
 */
@DataEntry
@ObjectClass(values = {"top", "oxAuthCustomScope"})
public class Scope implements Serializable {

    private static final long serialVersionUID = 4308826784917052508L;

    @DN
    private String dn;
    @AttributeName(ignoreDuringUpdate = true)
    private String inum;

    @AttributeName
    private String displayName;

    @AttributeName(name = "oxId")
    private String id;

    @AttributeName(name = "oxIconUrl")
    private String iconUrl;

    @AttributeName
    private String description;

    @AttributeName(name = "oxScopeType")
    private ScopeType scopeType;
 
    @AttributeName(name = "oxAuthClaim")
    private List<String> oxAuthClaims;

    @AttributeName(name = "defaultScope")
    private Boolean defaultScope;

    @AttributeName(name = "oxAuthGroupClaims")
    private Boolean oxAuthGroupClaims;

    @AttributeName(name = "oxScriptDn")
    private List<String> dynamicScopeScripts;

    @AttributeName(name = "oxUmaPolicyScriptDn")
    private List<String> umaAuthorizationPolicies;

    public String getDn() {
        return dn;
    }

    public void setDn(String dn) {
        this.dn = dn;
    }

    public String getInum() {
        return this.inum;
    }

    public void setInum(String inum) {
        this.inum = inum;
    }

    public String getDisplayName() {
        if(this.displayName==null){
            return getId();
        }else {
            return this.displayName;
        }
    }

    public void setDisplayName(String displayName) {
        this.displayName = displayName;
    }

    public String getDescription() {
        return this.description;
    }

    public void setDescription(String description) {
{'fraction_non_alphanumeric': 0.09927470534904805, 'fraction_numerical': 0.019492293744333637, 'mean_word_length': 3.2844660194174757, 'pattern_counts': {'":': 0, '<': 13, '<?xml version=': 0, '>': 13, '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': '2406072', 'n_tokens_mistral': 1420, 'n_tokens_neox': 1319, 'n_words': 318}