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

Bynder / bynder-java-sdk / 23339154263

09 Mar 2026 02:44PM UTC coverage: 39.99%. Remained the same
23339154263

Pull #153

github

web-flow
update sdk to version 2.2.30 (#152)
Pull Request #153: Add query support for assets that are assigned to a specific collection

1 of 1 new or added line in 1 file covered. (100.0%)

6 existing lines in 1 file now uncovered.

791 of 1978 relevant lines covered (39.99%)

0.4 hits per line

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

86.54
/src/main/java/com/bynder/sdk/query/MediaQuery.java
1
/*
2
 * Copyright (c) 2017 Bynder B.V. All rights reserved.
3
 *
4
 * Licensed under the MIT License. See LICENSE file in the project root for full license
5
 * information.
6
 */
7
package com.bynder.sdk.query;
8

9
import com.bynder.sdk.model.MediaType;
10
import com.bynder.sdk.query.decoder.ApiField;
11
import com.bynder.sdk.query.decoder.BooleanParameterDecoder;
12
import com.bynder.sdk.query.decoder.MetapropertyParameterDecoder;
13
import com.bynder.sdk.query.decoder.StringArrayParameterDecoder;
14

15
import java.util.List;
16
import java.util.Map;
17

18
/**
19
 * Query to filter media results.
20
 */
21
public class MediaQuery {
1✔
22

23
    /**
24
     * The type of the media asset. Possible values: image, document, audio, video.
25
     */
26
    @ApiField
27
    private MediaType type;
28
    /**
29
     * Keyword that the media asset has to have to appear in the results. Search filenames, tags,
30
     * extensions, collection names, guidelines, brandstore, campaigns in workflow, enriched PDFs,
31
     * word documents.
32
     */
33
    @ApiField
34
    private String keyword;
35
    /**
36
     * This property has to be set to 1 (TRUE) for the API to retrieved only media assets marked as
37
     * public.
38
     */
39
    @ApiField(decoder = BooleanParameterDecoder.class)
40
    private Boolean isPublic;
41
    /**
42
     * This property has to be set to 1 (TRUE) for the API to also retrieve media assets marked as
43
     * limited.
44
     */
45
    @ApiField(decoder = BooleanParameterDecoder.class)
46
    private Boolean limited;
47
    /**
48
     * Whether to fetch the media item information or not.
49
     */
50
    @ApiField(decoder = BooleanParameterDecoder.class)
51
    private Boolean includeMediaItems;
52
    /**
53
     * Limit of results per request. Maximum: 1000. Default: 50.
54
     */
55
    @ApiField
56
    private Integer limit;
57
    /**
58
     * Page to be retrieved.
59
     */
60
    @ApiField
61
    private Integer page;
62
    /**
63
     * Comma-separated tags to be retrieved.
64
     */
65
    @ApiField
66
    private String tags;
67
    /**
68
     * Metaproperty option ids that the media asset needs to have at least one of.
69
     */
70
    @ApiField(name = "propertyOptionId", decoder = StringArrayParameterDecoder.class)
71
    private String[] propertyOptionIds;
72
    /**
73
     * Desired order for the returned list of results.
74
     */
75
    @ApiField
76
    private OrderBy orderBy;
77
    /**
78
     * Retrieve assets created after this date.
79
     */
80
    @ApiField
81
    private String dateCreated;
82
    /**
83
     * Retrieve assets created up until this date.
84
     */
85
    @ApiField
86
    private String dateCreatedTo;
87
    /**
88
     * Retrieve assets created on this specific date
89
     */
90
    @ApiField
91
    private String dateCreatedOn;
92
    /**
93
     * Retrieve assets modified after this date.
94
     */
95
    @ApiField
96
    private String dateModified;
97
    /**
98
     * Retrieve assets modified up until this date.
99
     */
100
    @ApiField
101
    private String dateModifiedTo;
102
    /**
103
     * Retrieve assets modified on this specific date.
104
     */
105
    @ApiField
106
    private String dateModifiedOn;
107
    /**
108
     * Metaproperty option ids that the media asset has to have.
109
     */
110
    @ApiField(name = "property", decoder = MetapropertyParameterDecoder.class)
111
    private Map<String, String> metapropertyOptions;
112

113
    public MediaType getType() {
114
        return type;
1✔
115
    }
116

117
    public MediaQuery setType(final MediaType type) {
118
        this.type = type;
1✔
119
        return this;
1✔
120
    }
121

122
    public String getKeyword() {
123
        return keyword;
1✔
124
    }
125

126
    public MediaQuery setKeyword(final String keyword) {
127
        this.keyword = keyword;
1✔
128
        return this;
1✔
129
    }
130

131
    public Boolean getIsPublic() {
132
        return isPublic;
1✔
133
    }
134

135
    public MediaQuery setIsPublic(final Boolean isPublic) {
136
        this.isPublic = isPublic;
1✔
137
        return this;
1✔
138
    }
139

140
    public Boolean getLimited() {
141
        return limited;
1✔
142
    }
143

144
    public MediaQuery setLimited(final Boolean limited) {
145
        this.limited = limited;
1✔
146
        return this;
1✔
147
    }
148

149
    public Boolean getIncludeMediaItems() {
UNCOV
150
        return includeMediaItems;
×
151
    }
152

153
    public MediaQuery setIncludeMediaItems(final Boolean includeMediaItems) {
UNCOV
154
        this.includeMediaItems = includeMediaItems;
×
155
        return this;
×
156
    }
157

158
    public Integer getLimit() {
159
        return limit;
1✔
160
    }
161

162
    public MediaQuery setLimit(final Integer limit) {
163
        this.limit = limit;
1✔
164
        return this;
1✔
165
    }
166

167
    public Integer getPage() {
168
        return page;
1✔
169
    }
170

171
    public MediaQuery setPage(final Integer page) {
172
        this.page = page;
1✔
173
        return this;
1✔
174
    }
175

176
    public String getTags() {
177
        return tags;
1✔
178
    }
179

180
    public MediaQuery setTags(final List<String> tags) {
181
        this.tags = String.join(",", tags);
1✔
182
        return this;
1✔
183
    }
184

185
    public String[] getPropertyOptionIds() {
186
        return propertyOptionIds;
1✔
187
    }
188

189
    public MediaQuery setPropertyOptionIds(final String... propertyOptionIds) {
190
        this.propertyOptionIds = propertyOptionIds;
1✔
191
        return this;
1✔
192
    }
193

194
    public OrderBy getOrderBy() {
195
        return orderBy;
1✔
196
    }
197

198
    public MediaQuery setOrderBy(final OrderBy orderBy) {
199
        this.orderBy = orderBy;
1✔
200
        return this;
1✔
201
    }
202

203
    public String getDateCreated() {
204
        return dateCreated;
1✔
205
    }
206

207
    public MediaQuery setDateCreated(final String dateCreated) {
208
        this.dateCreated = dateCreated;
1✔
209
        return this;
1✔
210
    }
211

212
    public String getDateCreatedTo() {
213
        return dateCreatedTo;
1✔
214
    }
215

216
    public MediaQuery setDateCreatedTo(final String dateCreatedTo) {
217
        this.dateCreatedTo = dateCreatedTo;
1✔
218
        return this;
1✔
219
    }
220

221
    public String getDateCreatedOn() {
222
        return dateCreatedOn;
1✔
223
    }
224

225
    public MediaQuery setDateCreatedOn(final String dateCreatedOn) {
226
        this.dateCreatedOn = dateCreatedOn;
1✔
227
        return this;
1✔
228
    }
229

230
    public String getDateModified() {
231
        return dateModified;
1✔
232
    }
233

234
    public MediaQuery setDateModified(final String dateModified) {
235
        this.dateModified = dateModified;
1✔
236
        return this;
1✔
237
    }
238

239
    public String getDateModifiedTo() {
240
        return dateModifiedTo;
1✔
241
    }
242

243
    public MediaQuery setDateModifiedTo(final String dateModifiedTo) {
UNCOV
244
        this.dateModifiedTo = dateModifiedTo;
×
UNCOV
245
        return this;
×
246
    }
247

248
    public String getDateModifiedOn() {
249
        return dateModifiedOn;
1✔
250
    }
251

252
    public MediaQuery setDateModifiedOn(final String dateModifiedOn) {
UNCOV
253
        this.dateModifiedOn = dateModifiedOn;
×
UNCOV
254
        return this;
×
255
    }
256

257
    public Map<String, String> getMetapropertyOptions() {
258
        return metapropertyOptions;
1✔
259
    }
260

261
    public MediaQuery setMetapropertyOptions(final Map<String, String> metapropertyOptions) {
262
        this.metapropertyOptions = metapropertyOptions;
1✔
263
        return this;
1✔
264
    }
265
}
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