All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.alauda.kubernetes.api.model.WatchEvent Maven / Gradle / Ivy

There is a newer version: 0.2.12
Show newest version
/**
 * Copyright (C) 2018 Alauda, Inc.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *         http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package io.alauda.kubernetes.api.model;


import com.fasterxml.jackson.annotation.JsonAnyGetter;
import com.fasterxml.jackson.annotation.JsonAnySetter;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import io.sundr.builder.annotations.Buildable;
import io.sundr.builder.annotations.Inline;
import lombok.EqualsAndHashCode;
import lombok.ToString;

import javax.validation.Valid;
import java.util.HashMap;
import java.util.Map;

/**
 *
 *
 */
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonPropertyOrder({
    "object",
    "type"
})
@JsonDeserialize(using = com.fasterxml.jackson.databind.JsonDeserializer.None.class)
@ToString
@EqualsAndHashCode
@Buildable(editableEnabled = false, validationEnabled = true, generateBuilderPackage = true, builderPackage = "io.alauda.kubernetes.api.builder", inline = @Inline(type = Doneable.class, prefix = "Doneable", value = "done"))
public class WatchEvent implements KubernetesResource
{

  /**
   *
   *
   */
  @JsonProperty("object")
  @Valid
  private KubernetesResource object;
  /**
   * the type of watch event; may be ADDED
   *
   */
  @JsonProperty("type")
  private String type;
  @JsonIgnore
  private Map additionalProperties = new HashMap();

  /**
   * No args constructor for use in serialization
   *
   */
  public WatchEvent() {
  }

  /**
   *
   * @param type
   * @param object
   */
  public WatchEvent(KubernetesResource object, String type) {
    this.object = object;
    this.type = type;
  }

  /**
   *
   *
   * @return
   *     The object
   */
  @JsonProperty("object")
  public KubernetesResource getObject() {
    return object;
  }

  /**
   *
   *
   * @param object
   *     The object
   */
  @JsonProperty("object")
  public void setObject(KubernetesResource object) {
    this.object = object;
  }

  /**
   * the type of watch event; may be ADDED
   *
   * @return
   *     The type
   */
  @JsonProperty("type")
  public String getType() {
    return type;
  }

  /**
   * the type of watch event; may be ADDED
   *
   * @param type
   *     The type
   */
  @JsonProperty("type")
  public void setType(String type) {
    this.type = type;
  }

  @JsonAnyGetter
  public Map getAdditionalProperties() {
    return this.additionalProperties;
  }

  @JsonAnySetter
  public void setAdditionalProperty(String name, Object value) {
    this.additionalProperties.put(name, value);
  }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy