001package com.box.sdkgen.schemas.aiagentlongtexttool; 002 003import com.box.sdkgen.internal.NullableFieldTracker; 004import com.box.sdkgen.internal.SerializableObject; 005import com.fasterxml.jackson.annotation.JsonFilter; 006import com.fasterxml.jackson.annotation.JsonProperty; 007import java.util.Objects; 008 009@JsonFilter("nullablePropertyFilter") 010public class AiAgentLongTextToolEmbeddingsStrategyField extends SerializableObject { 011 012 /** The strategy used for the AI agent for calculating embeddings. */ 013 protected String id; 014 015 /** The number of tokens per chunk. */ 016 @JsonProperty("num_tokens_per_chunk") 017 protected Long numTokensPerChunk; 018 019 public AiAgentLongTextToolEmbeddingsStrategyField() { 020 super(); 021 } 022 023 protected AiAgentLongTextToolEmbeddingsStrategyField(Builder builder) { 024 super(); 025 this.id = builder.id; 026 this.numTokensPerChunk = builder.numTokensPerChunk; 027 markNullableFieldsAsSet(builder.getExplicitlySetNullableFields()); 028 } 029 030 public String getId() { 031 return id; 032 } 033 034 public Long getNumTokensPerChunk() { 035 return numTokensPerChunk; 036 } 037 038 @Override 039 public boolean equals(Object o) { 040 if (this == o) { 041 return true; 042 } 043 if (o == null || getClass() != o.getClass()) { 044 return false; 045 } 046 AiAgentLongTextToolEmbeddingsStrategyField casted = 047 (AiAgentLongTextToolEmbeddingsStrategyField) o; 048 return Objects.equals(id, casted.id) 049 && Objects.equals(numTokensPerChunk, casted.numTokensPerChunk); 050 } 051 052 @Override 053 public int hashCode() { 054 return Objects.hash(id, numTokensPerChunk); 055 } 056 057 @Override 058 public String toString() { 059 return "AiAgentLongTextToolEmbeddingsStrategyField{" 060 + "id='" 061 + id 062 + '\'' 063 + ", " 064 + "numTokensPerChunk='" 065 + numTokensPerChunk 066 + '\'' 067 + "}"; 068 } 069 070 public static class Builder extends NullableFieldTracker { 071 072 protected String id; 073 074 protected Long numTokensPerChunk; 075 076 public Builder id(String id) { 077 this.id = id; 078 return this; 079 } 080 081 public Builder numTokensPerChunk(Long numTokensPerChunk) { 082 this.numTokensPerChunk = numTokensPerChunk; 083 return this; 084 } 085 086 public AiAgentLongTextToolEmbeddingsStrategyField build() { 087 return new AiAgentLongTextToolEmbeddingsStrategyField(this); 088 } 089 } 090}