• 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

0.0
/src/main/java/com/box/sdkgen/schemas/metadataquery/MetadataQueryOrderByField.java
1
package com.box.sdkgen.schemas.metadataquery;
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 MetadataQueryOrderByField extends SerializableObject {
11

12
  @JsonProperty("field_key")
13
  protected String fieldKey;
14

15
  @JsonDeserialize(
16
      using =
17
          MetadataQueryOrderByDirectionField.MetadataQueryOrderByDirectionFieldDeserializer.class)
18
  @JsonSerialize(
19
      using = MetadataQueryOrderByDirectionField.MetadataQueryOrderByDirectionFieldSerializer.class)
20
  protected EnumWrapper<MetadataQueryOrderByDirectionField> direction;
21

22
  public MetadataQueryOrderByField() {
23
    super();
×
24
  }
×
25

26
  protected MetadataQueryOrderByField(Builder builder) {
27
    super();
×
28
    this.fieldKey = builder.fieldKey;
×
29
    this.direction = builder.direction;
×
30
  }
×
31

32
  public String getFieldKey() {
33
    return fieldKey;
×
34
  }
35

36
  public EnumWrapper<MetadataQueryOrderByDirectionField> getDirection() {
37
    return direction;
×
38
  }
39

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

52
  @Override
53
  public int hashCode() {
54
    return Objects.hash(fieldKey, direction);
×
55
  }
56

57
  @Override
58
  public String toString() {
59
    return "MetadataQueryOrderByField{"
×
60
        + "fieldKey='"
61
        + fieldKey
62
        + '\''
63
        + ", "
64
        + "direction='"
65
        + direction
66
        + '\''
67
        + "}";
68
  }
69

NEW
70
  public static class Builder {
×
71

72
    protected String fieldKey;
73

74
    protected EnumWrapper<MetadataQueryOrderByDirectionField> direction;
75

76
    public Builder fieldKey(String fieldKey) {
77
      this.fieldKey = fieldKey;
×
78
      return this;
×
79
    }
80

81
    public Builder direction(MetadataQueryOrderByDirectionField direction) {
UNCOV
82
      this.direction = new EnumWrapper<MetadataQueryOrderByDirectionField>(direction);
×
83
      return this;
×
84
    }
85

86
    public Builder direction(EnumWrapper<MetadataQueryOrderByDirectionField> direction) {
UNCOV
87
      this.direction = direction;
×
88
      return this;
×
89
    }
90

91
    public MetadataQueryOrderByField build() {
92
      return new MetadataQueryOrderByField(this);
×
93
    }
94
  }
95
}
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