/* 
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 */

package dev.plexapi.sdk.models.operations;


import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import dev.plexapi.sdk.utils.Utils;
import java.lang.Override;
import java.lang.String;
import java.util.Objects;


public class GetGenresLibraryDirectory {

    @JsonProperty("fastKey")
    private String fastKey;

    @JsonProperty("key")
    private String key;

    @JsonProperty("title")
    private String title;

    @JsonProperty("type")
    private String type;

    @JsonCreator
    public GetGenresLibraryDirectory(
            @JsonProperty("fastKey") String fastKey,
            @JsonProperty("key") String key,
            @JsonProperty("title") String title,
            @JsonProperty("type") String type) {
        Utils.checkNotNull(fastKey, "fastKey");
        Utils.checkNotNull(key, "key");
        Utils.checkNotNull(title, "title");
        Utils.checkNotNull(type, "type");
        this.fastKey = fastKey;
        this.key = key;
        this.title = title;
        this.type = type;
    }

    @JsonIgnore
    public String fastKey() {
        return fastKey;
    }

    @JsonIgnore
    public String key() {
        return key;
    }

    @JsonIgnore
    public String title() {
        return title;
    }

    @JsonIgnore
    public String type() {
        return type;
    }

    public final static Builder builder() {
        return new Builder();
    }

    public GetGenresLibraryDirectory withFastKey(String fastKey) {
        Utils.checkNotNull(fastKey, "fastKey");
        this.fastKey = fastKey;
        return this;
    }

    public GetGenresLibraryDirectory withKey(String key) {
        Utils.checkNotNull(key, "key");
        this.key = key;
        return this;
    }

    public GetGenresLibraryDirectory withTitle(String title) {
        Utils.checkNotNull(title, "title");
        this.title = title;
        return this;
    }

    public GetGenresLibraryDirectory withType(String type) {
        Utils.checkNotNull(type, "type");
        this.type = type;
        return this;
    }
    
    @Override
    public boolean equals(java.lang.Object o) {
        if (this == o) {
            return true;
        }
        if (o == null || getClass() != o.getClass()) {
            return false;
        }
        GetGenresLibraryDirectory other = (GetGenresLibraryDirectory) o;
        return 
            Objects.deepEquals(this.fastKey, other.fastKey) &&
            Objects.deepEquals(this.key, other.key) &&
            Objects.deepEquals(this.title, other.title) &&
            Objects.deepEquals(this.type, other.type);
    }
    
    @Override
    public int hashCode() {
        return Objects.hash(
            fastKey,
            key,
            title,
            type);
    }
    
    @Override
    public String toString() {
        return Utils.toString(GetGenresLibraryDirectory.class,
                "fastKey", fastKey,
                "key", key,
                "title", title,
                "type", type);
    }
    
    public final static class Builder {
 
        private String fastKey;
 
        private String key;
 
        private String title;
 
        private String type;  
        
        private Builder() {
          // force use of static builder() method
        }

        public Builder fastKey(String fastKey) {
            Utils.checkNotNull(fastKey, "fastKey");
            this.fastKey = fastKey;
            return this;
        }

        public Builder key(String key) {
            Utils.checkNotNull(key, "key");
            this.key = key;
            return this;
        }

        public Builder title(String title) {
            Utils.checkNotNull(title, "title");
            this.title = title;
            return this;
        }

        public Builder type(String type) {
            Utils.checkNotNull(type, "type");
            this.type = type;
            return this;
        }
        
        public GetGenresLibraryDirectory build() {
            return new GetGenresLibraryDirectory(
                fastKey,
                key,
                title,
                type);
        }
    }
}

