package org.wso2.carbon.device.mgt.ios.dep.beans;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import java.io.Serializable;

/**
 * This class represents the Apple DEP created profile details.
 * The variables in this class are not camel case.
 * Because JSON object returned as a response from Apple DEP portal is directly mapped to this
 * class using Gson. So the variable names are mapped as keys for the key value pairs in the
 * JSON object.
 * The variables are declared as per the documentation of Apple DEP.
 */
@ApiModel(value = "Profile", description = "This class carries information " +
                                                       "related to profile details.")
public class Profile implements Serializable {

    private static final long serialVersionUID = 419800235670912679L;

    @ApiModelProperty(
            name = "profile_name",
            value = "Name for the profile.",
            required = false)
    private String profile_name;

    @ApiModelProperty(
            name = "url",
            value = "URL of the MDM server.",
            required = false)
    private String url;

    @ApiModelProperty(
            name = "is_supervised",
            value = "The device must be supervised or not.",
            required = false)
    private boolean is_supervised;

    @ApiModelProperty(
            name = "allow_pairing",
            value = "The device is allowed to pair with other devices or not.",
            required = false)
    private boolean allow_pairing;

    @ApiModelProperty(
            name = "is_mandatory",
            value = "The user can skip applying the MDM server profile or not.",
            required = false)
    private boolean is_mandatory;

    @ApiModelProperty(
            name = "is_mdm_removable",
            value = "The MDM server profile can be removed or not.",
            required = false)
    private boolean is_mdm_removable;

    @ApiModelProperty(
            name = "department",
            value = "The name of the department.",
            required = false)
    private String department;

    @ApiModelProperty(
            name = "org_magic",
            value = "A string that uniquely identifies various services that are managed by a " +
                    "single organization",
            required = false)
    private String org_magic;

    @ApiModelProperty(
            name = "anchor_certs",
            value = "Array of strings. Each string should contain a DER-encoded certificate " +
                    "converted to Base64 encoding. If provided, these certificates are used as " +
                    "trusted anchor certificates when evaluating the trust of the connection to " +
                    "the MDM server url",
            required = false)
    private String[] anchor_certs;

    @ApiModelProperty(
            name = "supervising_host_certs",
            value = "Array of strings. Each string contains a DER-encoded certificate converted " +
                    "to Base64 encoding. If provided, the device will continue to pair with a " +
                    "host possessing one of these certificates even when allow_pairing is set " +
                    "to false.",
            required = false)
    private String[] supervising_host_certs;

    @ApiModelProperty(
            name = "support_phone_number",
            value = "A support phone number of the organization.",
            required = false)
    private String support_phone_number;

    @ApiModelProperty(
            name = "support_email_address",
            value = "A support email address of the organization.",
            required = false)
    private String support_email_address;

    @ApiModelProperty(
            name = "skip_setup_items",
            value = "Array of strings. A list of setup panes to skip.",
            required = false)
    private String[] skip_setup_items;

    public String getProfileName() {
        return profile_name;
    }

    public void setProfileName(String profile_name) {
        this.profile_name = profile_name;
    }

    public String getUrl() {
        return url;
    }

    public void setUrl(String url) {
        this.url = url;
    }

    public boolean isSupervised() {
        return is_supervised;
    }

    public void setIsSupervised(boolean is_supervised) {
        this.is_supervised = is_supervised;
    }

    public boolean isAllowPairing() {
        return allow_pairing;
    }

    public void setAllowPairing(boolean allow_pairing) {
        this.allow_pairing = allow_pairing;
    }

    public boolean isMandatory() {
        return is_mandatory;
    }

    public void setIsMandatory(boolean is_mandatory) {
        this.is_mandatory = is_mandatory;
    }

    public boolean isMdmRemovable() {
        return is_mdm_removable;
    }

    public void setIsMdmRemovable(boolean is_mdm_removable) {
        this.is_mdm_removable = is_mdm_removable;
    }

    public String getDepartment() {
        return department;
    }

    public void setDepartment(String department) {
        this.department = department;
    }

    public String getOrgMagic() {
        return org_magic;
    }

    public void setOrgMagic(String org_magic) {
        this.org_magic = org_magic;
    }

    public String[] getAnchorCerts() {
        return anchor_certs;
    }

    public void setAnchorCerts(String[] anchor_certs) {
        this.anchor_certs = anchor_certs;
    }

    public String[] getSupervisingHostCerts() {
        return supervising_host_certs;
    }

    public void setSupervisingHostCerts(String[] supervising_host_certs) {
        this.supervising_host_certs = supervising_host_certs;
    }

    public String getSupportPhoneNumber() {
        return support_phone_number;
    }

    public void setSupportPhoneNumber(String support_phone_number) {
        this.support_phone_number = support_phone_number;
    }

    public String getSupportEmailAddress() {
        return support_email_address;
    }

    public void setSupportEmailAddress(String support_email_address) {
        this.support_email_address = support_email_address;
    }

    public String[] getSkipSetupItems() {
        return skip_setup_items;
    }

    public void setSkipSetupItems(String[] skip_setup_items) {
        this.skip_setup_items = skip_setup_items;
    }
}
