• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

box / box-java-sdk-gen / #294

24 Jun 2025 01:20PM UTC coverage: 35.662% (+0.03%) from 35.632%
#294

Pull #347

github

web-flow
Merge 2c100d09c into d8480ee6c
Pull Request #347: feat: Add Webhook Validation In Java (box/box-codegen#745)

68 of 82 new or added lines in 2 files covered. (82.93%)

11791 existing lines in 624 files now uncovered.

16939 of 47499 relevant lines covered (35.66%)

0.36 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

51.43
/src/main/java/com/box/sdkgen/schemas/aitextgen/AiTextGen.java
1
package com.box.sdkgen.schemas.aitextgen;
2

3
import com.box.sdkgen.internal.NullableFieldTracker;
4
import com.box.sdkgen.internal.SerializableObject;
5
import com.box.sdkgen.schemas.aiagentreferenceoraiagenttextgen.AiAgentReferenceOrAiAgentTextGen;
6
import com.box.sdkgen.schemas.aidialoguehistory.AiDialogueHistory;
7
import com.fasterxml.jackson.annotation.JsonFilter;
8
import com.fasterxml.jackson.annotation.JsonProperty;
9
import java.util.List;
10
import java.util.Objects;
11

12
@JsonFilter("nullablePropertyFilter")
13
public class AiTextGen extends SerializableObject {
14

15
  protected final String prompt;
16

17
  protected final List<AiTextGenItemsField> items;
18

19
  @JsonProperty("dialogue_history")
20
  protected List<AiDialogueHistory> dialogueHistory;
21

22
  @JsonProperty("ai_agent")
23
  protected AiAgentReferenceOrAiAgentTextGen aiAgent;
24

25
  public AiTextGen(
26
      @JsonProperty("prompt") String prompt,
27
      @JsonProperty("items") List<AiTextGenItemsField> items) {
28
    super();
×
UNCOV
29
    this.prompt = prompt;
×
UNCOV
30
    this.items = items;
×
UNCOV
31
  }
×
32

33
  protected AiTextGen(Builder builder) {
34
    super();
1✔
35
    this.prompt = builder.prompt;
1✔
36
    this.items = builder.items;
1✔
37
    this.dialogueHistory = builder.dialogueHistory;
1✔
38
    this.aiAgent = builder.aiAgent;
1✔
39
    markNullableFieldsAsSet(builder.getExplicitlySetNullableFields());
1✔
40
  }
1✔
41

42
  public String getPrompt() {
43
    return prompt;
1✔
44
  }
45

46
  public List<AiTextGenItemsField> getItems() {
47
    return items;
1✔
48
  }
49

50
  public List<AiDialogueHistory> getDialogueHistory() {
51
    return dialogueHistory;
1✔
52
  }
53

54
  public AiAgentReferenceOrAiAgentTextGen getAiAgent() {
55
    return aiAgent;
1✔
56
  }
57

58
  @Override
59
  public boolean equals(Object o) {
60
    if (this == o) {
×
UNCOV
61
      return true;
×
62
    }
63
    if (o == null || getClass() != o.getClass()) {
×
64
      return false;
×
65
    }
66
    AiTextGen casted = (AiTextGen) o;
×
UNCOV
67
    return Objects.equals(prompt, casted.prompt)
×
UNCOV
68
        && Objects.equals(items, casted.items)
×
UNCOV
69
        && Objects.equals(dialogueHistory, casted.dialogueHistory)
×
UNCOV
70
        && Objects.equals(aiAgent, casted.aiAgent);
×
71
  }
72

73
  @Override
74
  public int hashCode() {
UNCOV
75
    return Objects.hash(prompt, items, dialogueHistory, aiAgent);
×
76
  }
77

78
  @Override
79
  public String toString() {
UNCOV
80
    return "AiTextGen{"
×
81
        + "prompt='"
82
        + prompt
83
        + '\''
84
        + ", "
85
        + "items='"
86
        + items
87
        + '\''
88
        + ", "
89
        + "dialogueHistory='"
90
        + dialogueHistory
91
        + '\''
92
        + ", "
93
        + "aiAgent='"
94
        + aiAgent
95
        + '\''
96
        + "}";
97
  }
98

99
  public static class Builder extends NullableFieldTracker {
100

101
    protected final String prompt;
102

103
    protected final List<AiTextGenItemsField> items;
104

105
    protected List<AiDialogueHistory> dialogueHistory;
106

107
    protected AiAgentReferenceOrAiAgentTextGen aiAgent;
108

109
    public Builder(String prompt, List<AiTextGenItemsField> items) {
110
      super();
1✔
111
      this.prompt = prompt;
1✔
112
      this.items = items;
1✔
113
    }
1✔
114

115
    public Builder dialogueHistory(List<AiDialogueHistory> dialogueHistory) {
116
      this.dialogueHistory = dialogueHistory;
1✔
117
      return this;
1✔
118
    }
119

120
    public Builder aiAgent(AiAgentReferenceOrAiAgentTextGen aiAgent) {
UNCOV
121
      this.aiAgent = aiAgent;
×
UNCOV
122
      return this;
×
123
    }
124

125
    public AiTextGen build() {
126
      return new AiTextGen(this);
1✔
127
    }
128
  }
129
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc