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

box / box-java-sdk-gen / #226

20 Jun 2025 03:14PM UTC coverage: 35.609% (-0.2%) from 35.816%
#226

push

github

web-flow
feat: Shorten builder names in Java (box/box-codegen#742) (#334)

367 of 1570 new or added lines in 984 files covered. (23.38%)

674 existing lines in 370 files now uncovered.

16125 of 45284 relevant lines covered (35.61%)

0.36 hits per line

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

12.5
/src/main/java/com/box/sdkgen/schemas/workflowmini/WorkflowMini.java
1
package com.box.sdkgen.schemas.workflowmini;
2

3
import com.box.sdkgen.internal.SerializableObject;
4
import com.box.sdkgen.serialization.json.EnumWrapper;
5
import com.fasterxml.jackson.annotation.JsonProperty;
6
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
7
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
8
import java.util.Objects;
9

10
public class WorkflowMini extends SerializableObject {
11

12
  protected String id;
13

14
  @JsonDeserialize(using = WorkflowMiniTypeField.WorkflowMiniTypeFieldDeserializer.class)
15
  @JsonSerialize(using = WorkflowMiniTypeField.WorkflowMiniTypeFieldSerializer.class)
16
  protected EnumWrapper<WorkflowMiniTypeField> type;
17

18
  protected String name;
19

20
  protected String description;
21

22
  @JsonProperty("is_enabled")
23
  protected Boolean isEnabled;
24

25
  public WorkflowMini() {
26
    super();
1✔
27
  }
1✔
28

29
  protected WorkflowMini(Builder builder) {
30
    super();
×
31
    this.id = builder.id;
×
32
    this.type = builder.type;
×
33
    this.name = builder.name;
×
34
    this.description = builder.description;
×
35
    this.isEnabled = builder.isEnabled;
×
36
  }
×
37

38
  public String getId() {
39
    return id;
1✔
40
  }
41

42
  public EnumWrapper<WorkflowMiniTypeField> getType() {
43
    return type;
1✔
44
  }
45

46
  public String getName() {
47
    return name;
×
48
  }
49

50
  public String getDescription() {
51
    return description;
×
52
  }
53

54
  public Boolean getIsEnabled() {
55
    return isEnabled;
1✔
56
  }
57

58
  @Override
59
  public boolean equals(Object o) {
60
    if (this == o) {
×
61
      return true;
×
62
    }
63
    if (o == null || getClass() != o.getClass()) {
×
64
      return false;
×
65
    }
66
    WorkflowMini casted = (WorkflowMini) o;
×
67
    return Objects.equals(id, casted.id)
×
68
        && Objects.equals(type, casted.type)
×
69
        && Objects.equals(name, casted.name)
×
70
        && Objects.equals(description, casted.description)
×
71
        && Objects.equals(isEnabled, casted.isEnabled);
×
72
  }
73

74
  @Override
75
  public int hashCode() {
76
    return Objects.hash(id, type, name, description, isEnabled);
×
77
  }
78

79
  @Override
80
  public String toString() {
81
    return "WorkflowMini{"
×
82
        + "id='"
83
        + id
84
        + '\''
85
        + ", "
86
        + "type='"
87
        + type
88
        + '\''
89
        + ", "
90
        + "name='"
91
        + name
92
        + '\''
93
        + ", "
94
        + "description='"
95
        + description
96
        + '\''
97
        + ", "
98
        + "isEnabled='"
99
        + isEnabled
100
        + '\''
101
        + "}";
102
  }
103

NEW
104
  public static class Builder {
×
105

106
    protected String id;
107

108
    protected EnumWrapper<WorkflowMiniTypeField> type;
109

110
    protected String name;
111

112
    protected String description;
113

114
    protected Boolean isEnabled;
115

116
    public Builder id(String id) {
117
      this.id = id;
×
118
      return this;
×
119
    }
120

121
    public Builder type(WorkflowMiniTypeField type) {
122
      this.type = new EnumWrapper<WorkflowMiniTypeField>(type);
×
123
      return this;
×
124
    }
125

126
    public Builder type(EnumWrapper<WorkflowMiniTypeField> type) {
127
      this.type = type;
×
128
      return this;
×
129
    }
130

131
    public Builder name(String name) {
132
      this.name = name;
×
133
      return this;
×
134
    }
135

136
    public Builder description(String description) {
137
      this.description = description;
×
138
      return this;
×
139
    }
140

141
    public Builder isEnabled(Boolean isEnabled) {
142
      this.isEnabled = isEnabled;
×
143
      return this;
×
144
    }
145

146
    public WorkflowMini build() {
147
      return new WorkflowMini(this);
×
148
    }
149
  }
150
}
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