001package com.box.sdkgen.schemas.aimultipleagentresponse; 002 003import com.box.sdkgen.internal.Nullable; 004import com.box.sdkgen.internal.NullableFieldTracker; 005import com.box.sdkgen.internal.SerializableObject; 006import com.box.sdkgen.schemas.aisingleagentresponsefull.AiSingleAgentResponseFull; 007import com.fasterxml.jackson.annotation.JsonFilter; 008import com.fasterxml.jackson.annotation.JsonProperty; 009import java.util.List; 010import java.util.Objects; 011 012/** List of AI Agents with pagination. */ 013@JsonFilter("nullablePropertyFilter") 014public class AiMultipleAgentResponse extends SerializableObject { 015 016 /** 017 * The limit that was used for these entries. This will be the same as the `limit` query parameter 018 * unless that value exceeded the maximum value allowed. The maximum value varies by API. 019 */ 020 protected Long limit; 021 022 /** The marker for the start of the next page of results. */ 023 @JsonProperty("next_marker") 024 @Nullable 025 protected String nextMarker; 026 027 /** The marker for the start of the previous page of results. */ 028 @JsonProperty("prev_marker") 029 @Nullable 030 protected String prevMarker; 031 032 /** The list of AI Agents. */ 033 protected final List<AiSingleAgentResponseFull> entries; 034 035 public AiMultipleAgentResponse(@JsonProperty("entries") List<AiSingleAgentResponseFull> entries) { 036 super(); 037 this.entries = entries; 038 } 039 040 protected AiMultipleAgentResponse(Builder builder) { 041 super(); 042 this.limit = builder.limit; 043 this.nextMarker = builder.nextMarker; 044 this.prevMarker = builder.prevMarker; 045 this.entries = builder.entries; 046 markNullableFieldsAsSet(builder.getExplicitlySetNullableFields()); 047 } 048 049 public Long getLimit() { 050 return limit; 051 } 052 053 public String getNextMarker() { 054 return nextMarker; 055 } 056 057 public String getPrevMarker() { 058 return prevMarker; 059 } 060 061 public List<AiSingleAgentResponseFull> getEntries() { 062 return entries; 063 } 064 065 @Override 066 public boolean equals(Object o) { 067 if (this == o) { 068 return true; 069 } 070 if (o == null || getClass() != o.getClass()) { 071 return false; 072 } 073 AiMultipleAgentResponse casted = (AiMultipleAgentResponse) o; 074 return Objects.equals(limit, casted.limit) 075 && Objects.equals(nextMarker, casted.nextMarker) 076 && Objects.equals(prevMarker, casted.prevMarker) 077 && Objects.equals(entries, casted.entries); 078 } 079 080 @Override 081 public int hashCode() { 082 return Objects.hash(limit, nextMarker, prevMarker, entries); 083 } 084 085 @Override 086 public String toString() { 087 return "AiMultipleAgentResponse{" 088 + "limit='" 089 + limit 090 + '\'' 091 + ", " 092 + "nextMarker='" 093 + nextMarker 094 + '\'' 095 + ", " 096 + "prevMarker='" 097 + prevMarker 098 + '\'' 099 + ", " 100 + "entries='" 101 + entries 102 + '\'' 103 + "}"; 104 } 105 106 public static class Builder extends NullableFieldTracker { 107 108 protected Long limit; 109 110 protected String nextMarker; 111 112 protected String prevMarker; 113 114 protected final List<AiSingleAgentResponseFull> entries; 115 116 public Builder(List<AiSingleAgentResponseFull> entries) { 117 super(); 118 this.entries = entries; 119 } 120 121 public Builder limit(Long limit) { 122 this.limit = limit; 123 return this; 124 } 125 126 public Builder nextMarker(String nextMarker) { 127 this.nextMarker = nextMarker; 128 this.markNullableFieldAsSet("next_marker"); 129 return this; 130 } 131 132 public Builder prevMarker(String prevMarker) { 133 this.prevMarker = prevMarker; 134 this.markNullableFieldAsSet("prev_marker"); 135 return this; 136 } 137 138 public AiMultipleAgentResponse build() { 139 return new AiMultipleAgentResponse(this); 140 } 141 } 142}