• 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

3.74
/src/main/java/com/box/sdkgen/schemas/trashweblink/TrashWebLink.java
1
package com.box.sdkgen.schemas.trashweblink;
2

3
import com.box.sdkgen.internal.SerializableObject;
4
import com.box.sdkgen.internal.utils.DateTimeUtils;
5
import com.box.sdkgen.schemas.foldermini.FolderMini;
6
import com.box.sdkgen.schemas.usermini.UserMini;
7
import com.box.sdkgen.serialization.json.EnumWrapper;
8
import com.fasterxml.jackson.annotation.JsonProperty;
9
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
10
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
11
import java.util.Date;
12
import java.util.Objects;
13

14
public class TrashWebLink extends SerializableObject {
15

16
  @JsonDeserialize(using = TrashWebLinkTypeField.TrashWebLinkTypeFieldDeserializer.class)
17
  @JsonSerialize(using = TrashWebLinkTypeField.TrashWebLinkTypeFieldSerializer.class)
18
  protected EnumWrapper<TrashWebLinkTypeField> type;
19

20
  protected String id;
21

22
  @JsonProperty("sequence_id")
23
  protected String sequenceId;
24

25
  protected String etag;
26

27
  protected String name;
28

29
  protected String url;
30

31
  protected FolderMini parent;
32

33
  protected String description;
34

35
  @JsonProperty("path_collection")
36
  protected TrashWebLinkPathCollectionField pathCollection;
37

38
  @JsonProperty("created_at")
39
  @JsonSerialize(using = DateTimeUtils.DateTimeSerializer.class)
40
  @JsonDeserialize(using = DateTimeUtils.DateTimeDeserializer.class)
41
  protected Date createdAt;
42

43
  @JsonProperty("modified_at")
44
  @JsonSerialize(using = DateTimeUtils.DateTimeSerializer.class)
45
  @JsonDeserialize(using = DateTimeUtils.DateTimeDeserializer.class)
46
  protected Date modifiedAt;
47

48
  @JsonProperty("trashed_at")
49
  @JsonSerialize(using = DateTimeUtils.DateTimeSerializer.class)
50
  @JsonDeserialize(using = DateTimeUtils.DateTimeDeserializer.class)
51
  protected Date trashedAt;
52

53
  @JsonProperty("purged_at")
54
  @JsonSerialize(using = DateTimeUtils.DateTimeSerializer.class)
55
  @JsonDeserialize(using = DateTimeUtils.DateTimeDeserializer.class)
56
  protected Date purgedAt;
57

58
  @JsonProperty("created_by")
59
  protected UserMini createdBy;
60

61
  @JsonProperty("modified_by")
62
  protected UserMini modifiedBy;
63

64
  @JsonProperty("owned_by")
65
  protected UserMini ownedBy;
66

67
  @JsonProperty("shared_link")
68
  protected String sharedLink;
69

70
  @JsonDeserialize(
71
      using = TrashWebLinkItemStatusField.TrashWebLinkItemStatusFieldDeserializer.class)
72
  @JsonSerialize(using = TrashWebLinkItemStatusField.TrashWebLinkItemStatusFieldSerializer.class)
73
  @JsonProperty("item_status")
74
  protected EnumWrapper<TrashWebLinkItemStatusField> itemStatus;
75

76
  public TrashWebLink() {
77
    super();
1✔
78
  }
1✔
79

80
  protected TrashWebLink(TrashWebLinkBuilder builder) {
81
    super();
×
82
    this.type = builder.type;
×
83
    this.id = builder.id;
×
84
    this.sequenceId = builder.sequenceId;
×
85
    this.etag = builder.etag;
×
86
    this.name = builder.name;
×
87
    this.url = builder.url;
×
88
    this.parent = builder.parent;
×
89
    this.description = builder.description;
×
90
    this.pathCollection = builder.pathCollection;
×
UNCOV
91
    this.createdAt = builder.createdAt;
×
UNCOV
92
    this.modifiedAt = builder.modifiedAt;
×
93
    this.trashedAt = builder.trashedAt;
×
UNCOV
94
    this.purgedAt = builder.purgedAt;
×
UNCOV
95
    this.createdBy = builder.createdBy;
×
UNCOV
96
    this.modifiedBy = builder.modifiedBy;
×
UNCOV
97
    this.ownedBy = builder.ownedBy;
×
UNCOV
98
    this.sharedLink = builder.sharedLink;
×
UNCOV
99
    this.itemStatus = builder.itemStatus;
×
UNCOV
100
  }
×
101

102
  public EnumWrapper<TrashWebLinkTypeField> getType() {
UNCOV
103
    return type;
×
104
  }
105

106
  public String getId() {
107
    return id;
1✔
108
  }
109

110
  public String getSequenceId() {
UNCOV
111
    return sequenceId;
×
112
  }
113

114
  public String getEtag() {
UNCOV
115
    return etag;
×
116
  }
117

118
  public String getName() {
119
    return name;
1✔
120
  }
121

122
  public String getUrl() {
UNCOV
123
    return url;
×
124
  }
125

126
  public FolderMini getParent() {
UNCOV
127
    return parent;
×
128
  }
129

130
  public String getDescription() {
UNCOV
131
    return description;
×
132
  }
133

134
  public TrashWebLinkPathCollectionField getPathCollection() {
UNCOV
135
    return pathCollection;
×
136
  }
137

138
  public Date getCreatedAt() {
UNCOV
139
    return createdAt;
×
140
  }
141

142
  public Date getModifiedAt() {
UNCOV
143
    return modifiedAt;
×
144
  }
145

146
  public Date getTrashedAt() {
UNCOV
147
    return trashedAt;
×
148
  }
149

150
  public Date getPurgedAt() {
UNCOV
151
    return purgedAt;
×
152
  }
153

154
  public UserMini getCreatedBy() {
UNCOV
155
    return createdBy;
×
156
  }
157

158
  public UserMini getModifiedBy() {
UNCOV
159
    return modifiedBy;
×
160
  }
161

162
  public UserMini getOwnedBy() {
UNCOV
163
    return ownedBy;
×
164
  }
165

166
  public String getSharedLink() {
167
    return sharedLink;
×
168
  }
169

170
  public EnumWrapper<TrashWebLinkItemStatusField> getItemStatus() {
UNCOV
171
    return itemStatus;
×
172
  }
173

174
  @Override
175
  public boolean equals(Object o) {
176
    if (this == o) {
×
177
      return true;
×
178
    }
179
    if (o == null || getClass() != o.getClass()) {
×
180
      return false;
×
181
    }
182
    TrashWebLink casted = (TrashWebLink) o;
×
183
    return Objects.equals(type, casted.type)
×
184
        && Objects.equals(id, casted.id)
×
185
        && Objects.equals(sequenceId, casted.sequenceId)
×
186
        && Objects.equals(etag, casted.etag)
×
187
        && Objects.equals(name, casted.name)
×
188
        && Objects.equals(url, casted.url)
×
189
        && Objects.equals(parent, casted.parent)
×
190
        && Objects.equals(description, casted.description)
×
UNCOV
191
        && Objects.equals(pathCollection, casted.pathCollection)
×
UNCOV
192
        && Objects.equals(createdAt, casted.createdAt)
×
UNCOV
193
        && Objects.equals(modifiedAt, casted.modifiedAt)
×
UNCOV
194
        && Objects.equals(trashedAt, casted.trashedAt)
×
195
        && Objects.equals(purgedAt, casted.purgedAt)
×
UNCOV
196
        && Objects.equals(createdBy, casted.createdBy)
×
UNCOV
197
        && Objects.equals(modifiedBy, casted.modifiedBy)
×
UNCOV
198
        && Objects.equals(ownedBy, casted.ownedBy)
×
UNCOV
199
        && Objects.equals(sharedLink, casted.sharedLink)
×
UNCOV
200
        && Objects.equals(itemStatus, casted.itemStatus);
×
201
  }
202

203
  @Override
204
  public int hashCode() {
UNCOV
205
    return Objects.hash(
×
206
        type,
207
        id,
208
        sequenceId,
209
        etag,
210
        name,
211
        url,
212
        parent,
213
        description,
214
        pathCollection,
215
        createdAt,
216
        modifiedAt,
217
        trashedAt,
218
        purgedAt,
219
        createdBy,
220
        modifiedBy,
221
        ownedBy,
222
        sharedLink,
223
        itemStatus);
224
  }
225

226
  @Override
227
  public String toString() {
UNCOV
228
    return "TrashWebLink{"
×
229
        + "type='"
230
        + type
231
        + '\''
232
        + ", "
233
        + "id='"
234
        + id
235
        + '\''
236
        + ", "
237
        + "sequenceId='"
238
        + sequenceId
239
        + '\''
240
        + ", "
241
        + "etag='"
242
        + etag
243
        + '\''
244
        + ", "
245
        + "name='"
246
        + name
247
        + '\''
248
        + ", "
249
        + "url='"
250
        + url
251
        + '\''
252
        + ", "
253
        + "parent='"
254
        + parent
255
        + '\''
256
        + ", "
257
        + "description='"
258
        + description
259
        + '\''
260
        + ", "
261
        + "pathCollection='"
262
        + pathCollection
263
        + '\''
264
        + ", "
265
        + "createdAt='"
266
        + createdAt
267
        + '\''
268
        + ", "
269
        + "modifiedAt='"
270
        + modifiedAt
271
        + '\''
272
        + ", "
273
        + "trashedAt='"
274
        + trashedAt
275
        + '\''
276
        + ", "
277
        + "purgedAt='"
278
        + purgedAt
279
        + '\''
280
        + ", "
281
        + "createdBy='"
282
        + createdBy
283
        + '\''
284
        + ", "
285
        + "modifiedBy='"
286
        + modifiedBy
287
        + '\''
288
        + ", "
289
        + "ownedBy='"
290
        + ownedBy
291
        + '\''
292
        + ", "
293
        + "sharedLink='"
294
        + sharedLink
295
        + '\''
296
        + ", "
297
        + "itemStatus='"
298
        + itemStatus
299
        + '\''
300
        + "}";
301
  }
302

UNCOV
303
  public static class TrashWebLinkBuilder {
×
304

305
    protected EnumWrapper<TrashWebLinkTypeField> type;
306

307
    protected String id;
308

309
    protected String sequenceId;
310

311
    protected String etag;
312

313
    protected String name;
314

315
    protected String url;
316

317
    protected FolderMini parent;
318

319
    protected String description;
320

321
    protected TrashWebLinkPathCollectionField pathCollection;
322

323
    protected Date createdAt;
324

325
    protected Date modifiedAt;
326

327
    protected Date trashedAt;
328

329
    protected Date purgedAt;
330

331
    protected UserMini createdBy;
332

333
    protected UserMini modifiedBy;
334

335
    protected UserMini ownedBy;
336

337
    protected String sharedLink;
338

339
    protected EnumWrapper<TrashWebLinkItemStatusField> itemStatus;
340

341
    public TrashWebLinkBuilder type(TrashWebLinkTypeField type) {
342
      this.type = new EnumWrapper<TrashWebLinkTypeField>(type);
×
343
      return this;
×
344
    }
345

346
    public TrashWebLinkBuilder type(EnumWrapper<TrashWebLinkTypeField> type) {
347
      this.type = type;
×
348
      return this;
×
349
    }
350

351
    public TrashWebLinkBuilder id(String id) {
352
      this.id = id;
×
353
      return this;
×
354
    }
355

356
    public TrashWebLinkBuilder sequenceId(String sequenceId) {
357
      this.sequenceId = sequenceId;
×
358
      return this;
×
359
    }
360

361
    public TrashWebLinkBuilder etag(String etag) {
362
      this.etag = etag;
×
363
      return this;
×
364
    }
365

366
    public TrashWebLinkBuilder name(String name) {
367
      this.name = name;
×
368
      return this;
×
369
    }
370

371
    public TrashWebLinkBuilder url(String url) {
372
      this.url = url;
×
373
      return this;
×
374
    }
375

376
    public TrashWebLinkBuilder parent(FolderMini parent) {
377
      this.parent = parent;
×
378
      return this;
×
379
    }
380

381
    public TrashWebLinkBuilder description(String description) {
382
      this.description = description;
×
383
      return this;
×
384
    }
385

386
    public TrashWebLinkBuilder pathCollection(TrashWebLinkPathCollectionField pathCollection) {
387
      this.pathCollection = pathCollection;
×
388
      return this;
×
389
    }
390

391
    public TrashWebLinkBuilder createdAt(Date createdAt) {
392
      this.createdAt = createdAt;
×
393
      return this;
×
394
    }
395

396
    public TrashWebLinkBuilder modifiedAt(Date modifiedAt) {
397
      this.modifiedAt = modifiedAt;
×
398
      return this;
×
399
    }
400

401
    public TrashWebLinkBuilder trashedAt(Date trashedAt) {
402
      this.trashedAt = trashedAt;
×
403
      return this;
×
404
    }
405

406
    public TrashWebLinkBuilder purgedAt(Date purgedAt) {
407
      this.purgedAt = purgedAt;
×
408
      return this;
×
409
    }
410

411
    public TrashWebLinkBuilder createdBy(UserMini createdBy) {
412
      this.createdBy = createdBy;
×
413
      return this;
×
414
    }
415

416
    public TrashWebLinkBuilder modifiedBy(UserMini modifiedBy) {
417
      this.modifiedBy = modifiedBy;
×
418
      return this;
×
419
    }
420

421
    public TrashWebLinkBuilder ownedBy(UserMini ownedBy) {
422
      this.ownedBy = ownedBy;
×
423
      return this;
×
424
    }
425

426
    public TrashWebLinkBuilder sharedLink(String sharedLink) {
427
      this.sharedLink = sharedLink;
×
428
      return this;
×
429
    }
430

431
    public TrashWebLinkBuilder itemStatus(TrashWebLinkItemStatusField itemStatus) {
432
      this.itemStatus = new EnumWrapper<TrashWebLinkItemStatusField>(itemStatus);
×
UNCOV
433
      return this;
×
434
    }
435

436
    public TrashWebLinkBuilder itemStatus(EnumWrapper<TrashWebLinkItemStatusField> itemStatus) {
UNCOV
437
      this.itemStatus = itemStatus;
×
UNCOV
438
      return this;
×
439
    }
440

441
    public TrashWebLink build() {
UNCOV
442
      return new TrashWebLink(this);
×
443
    }
444
  }
445
}
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