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

com.blazebit.query.connector.kandji.model.GetDeviceActivity200ResponseActivityResultsInner Maven / Gradle / Ivy

The newest version!
/*
 * Kandji API
 * # Welcome to the Kandji API Documentation  You can find your API URL in Settings > Access. The API URL will follow the below formats.  - US - `https://SubDomain.api.kandji.io` - EU - `https://SubDomain.api.eu.kandji.io`  For information on how to obtain an API token, please refer to the following support article.  [https://support.kandji.io/api](https://support.kandji.io/api)  #### Rate Limit  The Kandji API currently has an API rate limit of 10,000 requests per hour per customer.  #### Request Methods  HTTP request methods supported by the Kandji API.  | Method | Definition | | --- | --- | | GET | The `GET` method requests a representation of the specified resource. | | POST | The `POST` method submits an entity to the specified resource. | | PATCH | The `PATCH` method applies partial modifications to a resource. | | DELETE | The `DELETE` method deletes the specified resource. |  #### Response codes  Not all response codes apply to every endpoint.  | Code | Response | | --- | --- | | 200 | OK | | 201 | Created | | 204 | No content | |  | Typical response when sending the DELETE method. | | 400 | Bad Request | |  | \"Command already running\" - The command may already be running in a _Pending_ state waiting on the device. | |  | \"Command is not allowed for current device\" - The command may not be compatible with the target device. | |  | \"JSON parse error - Expecting ',' delimiter: line 3 column 2 (char 65)\" | | 401 | Unauthorized | |  | This error can occur if the token is incorrect, was revoked, or the token has expired. | | 403 | Forbidden | |  | The request was understood but cannot be authorized. | | 404 | Not found | |  | Unable to locate the resource in the Kandji tenant. | | 415 | Unsupported Media Type | |  | The request contains a media type which the server or resource does not support. | | 500 | Internal server error | | 503 | Service unavailable | |  | This error can occur if a file upload is still being processed via the custom apps API. |  #### Data structure  The API returns all structured responses in JSON schema format.  #### Examples  Code examples using the API can be found in the Kandji support [GitHub](https://github.com/kandji-inc/support/tree/main/api-tools).
 *
 * The version of the OpenAPI document: 1.0.0
 * 
 *
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
 * https://openapi-generator.tech
 * Do not edit the class manually.
 */


package com.blazebit.query.connector.kandji.model;

import java.util.Objects;
import java.util.Map;
import java.util.HashMap;
import com.blazebit.query.connector.kandji.model.GetDeviceActivity200ResponseActivityResultsInnerBlueprint;
import com.blazebit.query.connector.kandji.model.GetDeviceActivity200ResponseActivityResultsInnerComputer;
import com.blazebit.query.connector.kandji.model.GetDeviceActivity200ResponseActivityResultsInnerDetails;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonTypeName;
import com.fasterxml.jackson.annotation.JsonValue;
import java.math.BigDecimal;
import java.util.Arrays;
import org.openapitools.jackson.nullable.JsonNullable;
import com.fasterxml.jackson.annotation.JsonIgnore;
import org.openapitools.jackson.nullable.JsonNullable;
import java.util.NoSuchElementException;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import com.blazebit.query.connector.kandji.invoker.JSON;


/**
 * GetDeviceActivity200ResponseActivityResultsInner
 */
@JsonPropertyOrder({
  GetDeviceActivity200ResponseActivityResultsInner.JSON_PROPERTY_ACTION_TYPE,
  GetDeviceActivity200ResponseActivityResultsInner.JSON_PROPERTY_BLUEPRINT,
  GetDeviceActivity200ResponseActivityResultsInner.JSON_PROPERTY_COMPUTER,
  GetDeviceActivity200ResponseActivityResultsInner.JSON_PROPERTY_CREATED_AT,
  GetDeviceActivity200ResponseActivityResultsInner.JSON_PROPERTY_DETAILS,
  GetDeviceActivity200ResponseActivityResultsInner.JSON_PROPERTY_ID,
  GetDeviceActivity200ResponseActivityResultsInner.JSON_PROPERTY_USER
})
@JsonTypeName("getDeviceActivity_200_response_activity_results_inner")
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", date = "2025-04-30T07:19:31.168100307Z[Etc/UTC]", comments = "Generator version: 7.10.0")
public class GetDeviceActivity200ResponseActivityResultsInner {
  public static final String JSON_PROPERTY_ACTION_TYPE = "action_type";
  @jakarta.annotation.Nullable
  private String actionType;

  public static final String JSON_PROPERTY_BLUEPRINT = "blueprint";
  private JsonNullable blueprint = JsonNullable.undefined();

  public static final String JSON_PROPERTY_COMPUTER = "computer";
  @jakarta.annotation.Nullable
  private GetDeviceActivity200ResponseActivityResultsInnerComputer computer;

  public static final String JSON_PROPERTY_CREATED_AT = "created_at";
  @jakarta.annotation.Nullable
  private String createdAt;

  public static final String JSON_PROPERTY_DETAILS = "details";
  @jakarta.annotation.Nullable
  private GetDeviceActivity200ResponseActivityResultsInnerDetails details;

  public static final String JSON_PROPERTY_ID = "id";
  @jakarta.annotation.Nullable
  private BigDecimal id;

  public static final String JSON_PROPERTY_USER = "user";
  private JsonNullable user = JsonNullable.of(null);

  public GetDeviceActivity200ResponseActivityResultsInner() { 
  }

  public GetDeviceActivity200ResponseActivityResultsInner actionType(@jakarta.annotation.Nullable String actionType) {
    this.actionType = actionType;
    return this;
  }

  /**
   * Get actionType
   * @return actionType
   */
  @jakarta.annotation.Nullable
  @JsonProperty(JSON_PROPERTY_ACTION_TYPE)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public String getActionType() {
    return actionType;
  }


  @JsonProperty(JSON_PROPERTY_ACTION_TYPE)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setActionType(@jakarta.annotation.Nullable String actionType) {
    this.actionType = actionType;
  }


  public GetDeviceActivity200ResponseActivityResultsInner blueprint(@jakarta.annotation.Nullable GetDeviceActivity200ResponseActivityResultsInnerBlueprint blueprint) {
    this.blueprint = JsonNullable.of(blueprint);
    return this;
  }

  /**
   * Get blueprint
   * @return blueprint
   */
  @jakarta.annotation.Nullable
  @JsonIgnore

  public GetDeviceActivity200ResponseActivityResultsInnerBlueprint getBlueprint() {
        return blueprint.orElse(null);
  }

  @JsonProperty(JSON_PROPERTY_BLUEPRINT)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public JsonNullable getBlueprint_JsonNullable() {
    return blueprint;
  }
  
  @JsonProperty(JSON_PROPERTY_BLUEPRINT)
  public void setBlueprint_JsonNullable(JsonNullable blueprint) {
    this.blueprint = blueprint;
  }

  public void setBlueprint(@jakarta.annotation.Nullable GetDeviceActivity200ResponseActivityResultsInnerBlueprint blueprint) {
    this.blueprint = JsonNullable.of(blueprint);
  }


  public GetDeviceActivity200ResponseActivityResultsInner computer(@jakarta.annotation.Nullable GetDeviceActivity200ResponseActivityResultsInnerComputer computer) {
    this.computer = computer;
    return this;
  }

  /**
   * Get computer
   * @return computer
   */
  @jakarta.annotation.Nullable
  @JsonProperty(JSON_PROPERTY_COMPUTER)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public GetDeviceActivity200ResponseActivityResultsInnerComputer getComputer() {
    return computer;
  }


  @JsonProperty(JSON_PROPERTY_COMPUTER)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setComputer(@jakarta.annotation.Nullable GetDeviceActivity200ResponseActivityResultsInnerComputer computer) {
    this.computer = computer;
  }


  public GetDeviceActivity200ResponseActivityResultsInner createdAt(@jakarta.annotation.Nullable String createdAt) {
    this.createdAt = createdAt;
    return this;
  }

  /**
   * Get createdAt
   * @return createdAt
   */
  @jakarta.annotation.Nullable
  @JsonProperty(JSON_PROPERTY_CREATED_AT)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public String getCreatedAt() {
    return createdAt;
  }


  @JsonProperty(JSON_PROPERTY_CREATED_AT)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setCreatedAt(@jakarta.annotation.Nullable String createdAt) {
    this.createdAt = createdAt;
  }


  public GetDeviceActivity200ResponseActivityResultsInner details(@jakarta.annotation.Nullable GetDeviceActivity200ResponseActivityResultsInnerDetails details) {
    this.details = details;
    return this;
  }

  /**
   * Get details
   * @return details
   */
  @jakarta.annotation.Nullable
  @JsonProperty(JSON_PROPERTY_DETAILS)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public GetDeviceActivity200ResponseActivityResultsInnerDetails getDetails() {
    return details;
  }


  @JsonProperty(JSON_PROPERTY_DETAILS)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setDetails(@jakarta.annotation.Nullable GetDeviceActivity200ResponseActivityResultsInnerDetails details) {
    this.details = details;
  }


  public GetDeviceActivity200ResponseActivityResultsInner id(@jakarta.annotation.Nullable BigDecimal id) {
    this.id = id;
    return this;
  }

  /**
   * Get id
   * @return id
   */
  @jakarta.annotation.Nullable
  @JsonProperty(JSON_PROPERTY_ID)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public BigDecimal getId() {
    return id;
  }


  @JsonProperty(JSON_PROPERTY_ID)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setId(@jakarta.annotation.Nullable BigDecimal id) {
    this.id = id;
  }


  public GetDeviceActivity200ResponseActivityResultsInner user(@jakarta.annotation.Nullable Object user) {
    this.user = JsonNullable.of(user);
    return this;
  }

  /**
   * Get user
   * @return user
   */
  @jakarta.annotation.Nullable
  @JsonIgnore

  public Object getUser() {
        return user.orElse(null);
  }

  @JsonProperty(JSON_PROPERTY_USER)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public JsonNullable getUser_JsonNullable() {
    return user;
  }
  
  @JsonProperty(JSON_PROPERTY_USER)
  public void setUser_JsonNullable(JsonNullable user) {
    this.user = user;
  }

  public void setUser(@jakarta.annotation.Nullable Object user) {
    this.user = JsonNullable.of(user);
  }


  /**
   * Return true if this getDeviceActivity_200_response_activity_results_inner object is equal to o.
   */
  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    GetDeviceActivity200ResponseActivityResultsInner getDeviceActivity200ResponseActivityResultsInner = (GetDeviceActivity200ResponseActivityResultsInner) o;
    return Objects.equals(this.actionType, getDeviceActivity200ResponseActivityResultsInner.actionType) &&
        equalsNullable(this.blueprint, getDeviceActivity200ResponseActivityResultsInner.blueprint) &&
        Objects.equals(this.computer, getDeviceActivity200ResponseActivityResultsInner.computer) &&
        Objects.equals(this.createdAt, getDeviceActivity200ResponseActivityResultsInner.createdAt) &&
        Objects.equals(this.details, getDeviceActivity200ResponseActivityResultsInner.details) &&
        Objects.equals(this.id, getDeviceActivity200ResponseActivityResultsInner.id) &&
        equalsNullable(this.user, getDeviceActivity200ResponseActivityResultsInner.user);
  }

  private static  boolean equalsNullable(JsonNullable a, JsonNullable b) {
    return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get()));
  }

  @Override
  public int hashCode() {
    return Objects.hash(actionType, hashCodeNullable(blueprint), computer, createdAt, details, id, hashCodeNullable(user));
  }

  private static  int hashCodeNullable(JsonNullable a) {
    if (a == null) {
      return 1;
    }
    return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31;
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class GetDeviceActivity200ResponseActivityResultsInner {\n");
    sb.append("    actionType: ").append(toIndentedString(actionType)).append("\n");
    sb.append("    blueprint: ").append(toIndentedString(blueprint)).append("\n");
    sb.append("    computer: ").append(toIndentedString(computer)).append("\n");
    sb.append("    createdAt: ").append(toIndentedString(createdAt)).append("\n");
    sb.append("    details: ").append(toIndentedString(details)).append("\n");
    sb.append("    id: ").append(toIndentedString(id)).append("\n");
    sb.append("    user: ").append(toIndentedString(user)).append("\n");
    sb.append("}");
    return sb.toString();
  }

  /**
   * Convert the given object to string with each line indented by 4 spaces
   * (except the first line).
   */
  private String toIndentedString(Object o) {
    if (o == null) {
      return "null";
    }
    return o.toString().replace("\n", "\n    ");
  }

}