11package com .github .dockerjava .api .command ;
22
3+ import java .util .List ;
34import java .util .Map ;
45
56import javax .annotation .CheckForNull ;
@@ -225,29 +226,55 @@ public interface CreateContainerCmd extends SyncDockerCmd<CreateContainerRespons
225226 */
226227 public CreateContainerCmd withDevices (Device ... devices );
227228
229+ /**
230+ * Add host devices to the container
231+ */
232+ public CreateContainerCmd withDevices (List <Device > devices );
233+
228234 /**
229235 * Set custom DNS servers
230236 */
231237 public CreateContainerCmd withDns (String ... dns );
232238
239+ /**
240+ * Set custom DNS servers
241+ */
242+ public CreateContainerCmd withDns (List <String > dns );
243+
233244 /**
234245 * Set custom DNS search domains
235246 */
236247 public CreateContainerCmd withDnsSearch (String ... dnsSearch );
237248
249+ /**
250+ * Set custom DNS search domains
251+ */
252+ public CreateContainerCmd withDnsSearch (List <String > dnsSearch );
253+
238254 public CreateContainerCmd withDomainName (String domainName );
239255
240256 public CreateContainerCmd withEntrypoint (String ... entrypoint );
241257
258+ public CreateContainerCmd withEntrypoint (List <String > entrypoint );
259+
242260 public CreateContainerCmd withEnv (String ... env );
243261
262+ public CreateContainerCmd withEnv (List <String > env );
263+
244264 public CreateContainerCmd withExposedPorts (ExposedPort ... exposedPorts );
245265
266+ public CreateContainerCmd withExposedPorts (List <ExposedPort > exposedPorts );
267+
246268 /**
247269 * Add hostnames to /etc/hosts in the container
248270 */
249271 public CreateContainerCmd withExtraHosts (String ... extraHosts );
250272
273+ /**
274+ * Add hostnames to /etc/hosts in the container
275+ */
276+ public CreateContainerCmd withExtraHosts (List <String > extraHosts );
277+
251278 public CreateContainerCmd withHostName (String hostName );
252279
253280 public CreateContainerCmd withImage (String image );
@@ -259,10 +286,17 @@ public interface CreateContainerCmd extends SyncDockerCmd<CreateContainerRespons
259286 */
260287 public CreateContainerCmd withLinks (Link ... links );
261288
289+ /**
290+ * Add link to another container.
291+ */
292+ public CreateContainerCmd withLinks (List <Link > links );
293+
262294 public CreateContainerCmd withLogConfig (LogConfig logConfig );
263295
264296 public CreateContainerCmd withLxcConf (LxcConf ... lxcConf );
265297
298+ public CreateContainerCmd withLxcConf (List <LxcConf > lxcConf );
299+
266300 public CreateContainerCmd withMacAddress (String macAddress );
267301
268302 public CreateContainerCmd withMemory (Long memory );
@@ -296,6 +330,12 @@ public interface CreateContainerCmd extends SyncDockerCmd<CreateContainerRespons
296330 */
297331 public CreateContainerCmd withPortBindings (PortBinding ... portBindings );
298332
333+ /**
334+ * Add one or more {@link PortBinding}s. This corresponds to the <code>--publish</code> (<code>-p</code>) option of
335+ * the <code>docker run</code> CLI command.
336+ */
337+ public CreateContainerCmd withPortBindings (List <PortBinding > portBindings );
338+
299339 /**
300340 * Add the port bindings that are contained in the given {@link Ports} object.
301341 *
@@ -305,6 +345,8 @@ public interface CreateContainerCmd extends SyncDockerCmd<CreateContainerRespons
305345
306346 public CreateContainerCmd withPortSpecs (String ... portSpecs );
307347
348+ public CreateContainerCmd withPortSpecs (List <String > portSpecs );
349+
308350 public CreateContainerCmd withPrivileged (Boolean privileged );
309351
310352 public CreateContainerCmd withPublishAllPorts (Boolean publishAllPorts );
@@ -322,14 +364,20 @@ public interface CreateContainerCmd extends SyncDockerCmd<CreateContainerRespons
322364
323365 public CreateContainerCmd withTty (Boolean tty );
324366
325- public CreateContainerCmd withUlimits (Ulimit [] ulimits );
367+ public CreateContainerCmd withUlimits (Ulimit ... ulimits );
368+
369+ public CreateContainerCmd withUlimits (List <Ulimit > ulimits );
326370
327371 public CreateContainerCmd withUser (String user );
328372
329373 public CreateContainerCmd withVolumes (Volume ... volumes );
330374
375+ public CreateContainerCmd withVolumes (List <Volume > volumes );
376+
331377 public CreateContainerCmd withVolumesFrom (VolumesFrom ... volumesFrom );
332378
379+ public CreateContainerCmd withVolumesFrom (List <VolumesFrom > volumesFrom );
380+
333381 public CreateContainerCmd withWorkingDir (String workingDir );
334382
335383 /**
0 commit comments