• 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

50.0
/src/main/java/com/box/sdkgen/managers/fileversions/PromoteFileVersionRequestBody.java
1
package com.box.sdkgen.managers.fileversions;
2

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

9
public class PromoteFileVersionRequestBody extends SerializableObject {
10

11
  protected String id;
12

13
  @JsonDeserialize(
14
      using =
15
          PromoteFileVersionRequestBodyTypeField.PromoteFileVersionRequestBodyTypeFieldDeserializer
16
              .class)
17
  @JsonSerialize(
18
      using =
19
          PromoteFileVersionRequestBodyTypeField.PromoteFileVersionRequestBodyTypeFieldSerializer
20
              .class)
21
  protected EnumWrapper<PromoteFileVersionRequestBodyTypeField> type;
22

23
  public PromoteFileVersionRequestBody() {
24
    super();
×
25
  }
×
26

27
  protected PromoteFileVersionRequestBody(Builder builder) {
28
    super();
1✔
29
    this.id = builder.id;
1✔
30
    this.type = builder.type;
1✔
31
  }
1✔
32

33
  public String getId() {
34
    return id;
1✔
35
  }
36

37
  public EnumWrapper<PromoteFileVersionRequestBodyTypeField> getType() {
38
    return type;
1✔
39
  }
40

41
  @Override
42
  public boolean equals(Object o) {
43
    if (this == o) {
×
44
      return true;
×
45
    }
46
    if (o == null || getClass() != o.getClass()) {
×
47
      return false;
×
48
    }
49
    PromoteFileVersionRequestBody casted = (PromoteFileVersionRequestBody) o;
×
50
    return Objects.equals(id, casted.id) && Objects.equals(type, casted.type);
×
51
  }
52

53
  @Override
54
  public int hashCode() {
55
    return Objects.hash(id, type);
×
56
  }
57

58
  @Override
59
  public String toString() {
60
    return "PromoteFileVersionRequestBody{"
×
61
        + "id='"
62
        + id
63
        + '\''
64
        + ", "
65
        + "type='"
66
        + type
67
        + '\''
68
        + "}";
69
  }
70

71
  public static class Builder {
1✔
72

73
    protected String id;
74

75
    protected EnumWrapper<PromoteFileVersionRequestBodyTypeField> type;
76

77
    public Builder id(String id) {
78
      this.id = id;
1✔
79
      return this;
1✔
80
    }
81

82
    public Builder type(PromoteFileVersionRequestBodyTypeField type) {
83
      this.type = new EnumWrapper<PromoteFileVersionRequestBodyTypeField>(type);
1✔
84
      return this;
1✔
85
    }
86

87
    public Builder type(EnumWrapper<PromoteFileVersionRequestBodyTypeField> type) {
UNCOV
88
      this.type = type;
×
89
      return this;
×
90
    }
91

92
    public PromoteFileVersionRequestBody build() {
93
      return new PromoteFileVersionRequestBody(this);
1✔
94
    }
95
  }
96
}
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