// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest Code Generator.

package com.azure.communication.jobrouter.models;

import com.azure.core.annotation.Fluent;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonTypeInfo;
import com.fasterxml.jackson.annotation.JsonTypeName;

/** Describes a worker selector that will be attached to the job. */
@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "kind")
@JsonTypeName("static")
@Fluent
public final class StaticWorkerSelectorAttachment extends WorkerSelectorAttachment {
    /*
     * Describes a condition that must be met against a set of labels for
     * worker selection
     */
    @JsonProperty(value = "workerSelector", required = true)
    private RouterWorkerSelector workerSelector;

    /**
     * Get the workerSelector property: Describes a condition that must be met against a set of labels for worker
     * selection.
     *
     * @return the workerSelector value.
     */
    public RouterWorkerSelector getWorkerSelector() {
        return this.workerSelector;
    }

    /**
     * Set the workerSelector property: Describes a condition that must be met against a set of labels for worker
     * selection.
     *
     * @param workerSelector the workerSelector value to set.
     * @return the StaticWorkerSelectorAttachment object itself.
     */
    public StaticWorkerSelectorAttachment setWorkerSelector(RouterWorkerSelector workerSelector) {
        this.workerSelector = workerSelector;
        return this;
    }
}
