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

box / box-java-sdk-gen / #155

30 May 2025 01:03PM UTC coverage: 35.646% (+0.3%) from 35.311%
#155

push

github

web-flow
fix: Fix downscope token to use `retrieveToken` method for token retrieval (box/box-codegen#731) (#320)

4 of 4 new or added lines in 4 files covered. (100.0%)

2952 existing lines in 99 files now uncovered.

15628 of 43842 relevant lines covered (35.65%)

0.36 hits per line

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

23.53
/src/main/java/com/box/sdkgen/managers/uploads/UploadFileRequestBodyAttributesField.java
1
package com.box.sdkgen.managers.uploads;
2

3
import com.box.sdkgen.internal.SerializableObject;
4
import com.box.sdkgen.internal.utils.DateTimeUtils;
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.Date;
9
import java.util.Objects;
10

11
public class UploadFileRequestBodyAttributesField extends SerializableObject {
12

13
  protected final String name;
14

15
  protected final UploadFileRequestBodyAttributesParentField parent;
16

17
  @JsonProperty("content_created_at")
18
  @JsonSerialize(using = DateTimeUtils.DateTimeSerializer.class)
19
  @JsonDeserialize(using = DateTimeUtils.DateTimeDeserializer.class)
20
  protected Date contentCreatedAt;
21

22
  @JsonProperty("content_modified_at")
23
  @JsonSerialize(using = DateTimeUtils.DateTimeSerializer.class)
24
  @JsonDeserialize(using = DateTimeUtils.DateTimeDeserializer.class)
25
  protected Date contentModifiedAt;
26

27
  public UploadFileRequestBodyAttributesField(
28
      @JsonProperty("name") String name,
29
      @JsonProperty("parent") UploadFileRequestBodyAttributesParentField parent) {
30
    super();
1✔
31
    this.name = name;
1✔
32
    this.parent = parent;
1✔
33
  }
1✔
34

35
  protected UploadFileRequestBodyAttributesField(
36
      UploadFileRequestBodyAttributesFieldBuilder builder) {
UNCOV
37
    super();
×
UNCOV
38
    this.name = builder.name;
×
UNCOV
39
    this.parent = builder.parent;
×
UNCOV
40
    this.contentCreatedAt = builder.contentCreatedAt;
×
UNCOV
41
    this.contentModifiedAt = builder.contentModifiedAt;
×
UNCOV
42
  }
×
43

44
  public String getName() {
45
    return name;
1✔
46
  }
47

48
  public UploadFileRequestBodyAttributesParentField getParent() {
49
    return parent;
1✔
50
  }
51

52
  public Date getContentCreatedAt() {
53
    return contentCreatedAt;
1✔
54
  }
55

56
  public Date getContentModifiedAt() {
57
    return contentModifiedAt;
1✔
58
  }
59

60
  @Override
61
  public boolean equals(Object o) {
62
    if (this == o) {
×
63
      return true;
×
64
    }
UNCOV
65
    if (o == null || getClass() != o.getClass()) {
×
UNCOV
66
      return false;
×
67
    }
UNCOV
68
    UploadFileRequestBodyAttributesField casted = (UploadFileRequestBodyAttributesField) o;
×
69
    return Objects.equals(name, casted.name)
×
UNCOV
70
        && Objects.equals(parent, casted.parent)
×
UNCOV
71
        && Objects.equals(contentCreatedAt, casted.contentCreatedAt)
×
UNCOV
72
        && Objects.equals(contentModifiedAt, casted.contentModifiedAt);
×
73
  }
74

75
  @Override
76
  public int hashCode() {
UNCOV
77
    return Objects.hash(name, parent, contentCreatedAt, contentModifiedAt);
×
78
  }
79

80
  @Override
81
  public String toString() {
UNCOV
82
    return "UploadFileRequestBodyAttributesField{"
×
83
        + "name='"
84
        + name
85
        + '\''
86
        + ", "
87
        + "parent='"
88
        + parent
89
        + '\''
90
        + ", "
91
        + "contentCreatedAt='"
92
        + contentCreatedAt
93
        + '\''
94
        + ", "
95
        + "contentModifiedAt='"
96
        + contentModifiedAt
97
        + '\''
98
        + "}";
99
  }
100

101
  public static class UploadFileRequestBodyAttributesFieldBuilder {
102

103
    protected final String name;
104

105
    protected final UploadFileRequestBodyAttributesParentField parent;
106

107
    protected Date contentCreatedAt;
108

109
    protected Date contentModifiedAt;
110

111
    public UploadFileRequestBodyAttributesFieldBuilder(
UNCOV
112
        String name, UploadFileRequestBodyAttributesParentField parent) {
×
UNCOV
113
      this.name = name;
×
UNCOV
114
      this.parent = parent;
×
115
    }
×
116

117
    public UploadFileRequestBodyAttributesFieldBuilder contentCreatedAt(Date contentCreatedAt) {
UNCOV
118
      this.contentCreatedAt = contentCreatedAt;
×
UNCOV
119
      return this;
×
120
    }
121

122
    public UploadFileRequestBodyAttributesFieldBuilder contentModifiedAt(Date contentModifiedAt) {
UNCOV
123
      this.contentModifiedAt = contentModifiedAt;
×
UNCOV
124
      return this;
×
125
    }
126

127
    public UploadFileRequestBodyAttributesField build() {
UNCOV
128
      return new UploadFileRequestBodyAttributesField(this);
×
129
    }
130
  }
131
}
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