public void setContainers()

in aliyun-java-sdk-eci/src/main/java/com/aliyuncs/eci/model/v20180808/UpdateContainerGroupRequest.java [64:168]


	public void setContainers(List<Container> containers) {
		this.containers = containers;
		if (containers != null) {
			for (int depth1 = 0; depth1 < containers.size(); depth1++) {
				putQueryParameter("Container." + (depth1 + 1) + ".Image" , containers.get(depth1).getImage());
				putQueryParameter("Container." + (depth1 + 1) + ".Name" , containers.get(depth1).getName());
				putQueryParameter("Container." + (depth1 + 1) + ".Cpu" , containers.get(depth1).getCpu());
				putQueryParameter("Container." + (depth1 + 1) + ".Memory" , containers.get(depth1).getMemory());
				putQueryParameter("Container." + (depth1 + 1) + ".WorkingDir" , containers.get(depth1).getWorkingDir());
				putQueryParameter("Container." + (depth1 + 1) + ".ImagePullPolicy" , containers.get(depth1).getImagePullPolicy());
				putQueryParameter("Container." + (depth1 + 1) + ".Stdin", containers.get(depth1).getStdin());
				putQueryParameter("Container." + (depth1 + 1) + ".StdinOnce" , containers.get(depth1).getStdinOnce());
				putQueryParameter("Container." + (depth1 + 1) + ".Tty" , containers.get(depth1).getTty());
				putQueryParameter("Container." + (depth1 + 1) + ".Gpu" , containers.get(depth1).getGpu());

				if (containers.get(depth1).getCommands() != null) {
					for (int i = 0; i < containers.get(depth1).getCommands().size(); i++) {
						putQueryParameter("Container." + (depth1 + 1) + ".Command." + (i + 1) , containers.get(depth1).getCommands().get(i));
					}
				}
				if (containers.get(depth1).getArgs() != null) {
					for (int i = 0; i < containers.get(depth1).getArgs().size(); i++) {
						putQueryParameter("Container." + (depth1 + 1) + ".Arg." + (i + 1) , containers.get(depth1).getArgs().get(i));
					}
				}
				if (containers.get(depth1).getVolumeMounts() != null) {
					for (int depth2 = 0; depth2 < containers.get(depth1).getVolumeMounts().size(); depth2++) {
						putQueryParameter("Container." + (depth1 + 1) + ".VolumeMount." + (depth2 + 1) + ".MountPath" , containers.get(depth1).getVolumeMounts().get(depth2).getMountPath());
						putQueryParameter("Container." + (depth1 + 1) + ".VolumeMount." + (depth2 + 1) + ".ReadOnly" , containers.get(depth1).getVolumeMounts().get(depth2).getReadOnly());
						putQueryParameter("Container." + (depth1 + 1) + ".VolumeMount." + (depth2 + 1) + ".Name" , containers.get(depth1).getVolumeMounts().get(depth2).getName());
					}
				}
				if (containers.get(depth1).getPorts() != null) {
					for (int depth2 = 0; depth2 < containers.get(depth1).getPorts().size(); depth2++) {
						putQueryParameter("Container." + (depth1 + 1) + ".Port." + (depth2 + 1) + ".Protocol" , containers.get(depth1).getPorts().get(depth2).getProtocol());
						putQueryParameter("Container." + (depth1 + 1) + ".Port." + (depth2 + 1) + ".Port" , containers.get(depth1).getPorts().get(depth2).getPort());
					}
				}
				if (containers.get(depth1).getEnvironmentVars() != null) {
					for (int depth2 = 0; depth2 < containers.get(depth1).getEnvironmentVars().size(); depth2++) {
						putQueryParameter("Container." + (depth1 + 1) + ".EnvironmentVar." + (depth2 + 1) + ".Key" , containers.get(depth1).getEnvironmentVars().get(depth2).getKey());
						putQueryParameter("Container." + (depth1 + 1) + ".EnvironmentVar." + (depth2 + 1) + ".Value" , containers.get(depth1).getEnvironmentVars().get(depth2).getValue());
						putQueryParameter("Container." + (depth1 + 1) + ".EnvironmentVar." + (depth2 + 1) + ".FieldRef.FieldPath" , containers.get(depth1).getEnvironmentVars().get(depth2).getFieldRefFieldPath());
					}
				}

				if(containers.get(depth1).getReadinessProbe() != null){
					if(containers.get(depth1).getReadinessProbe().getExec() != null){
						for (int i = 0; i < containers.get(depth1).getReadinessProbe().getExec().size(); i++) {
							putQueryParameter("Container." + (depth1 + 1) + ".ReadinessProbe.Exec.Command." + (i + 1) , containers.get(depth1).getReadinessProbe().getExec().get(i));
						}
					}
					if(containers.get(depth1).getReadinessProbe().getHttpGet() != null){
						putQueryParameter("Container." + (depth1 + 1) + ".ReadinessProbe.HttpGet.Path" , containers.get(depth1).getReadinessProbe().getHttpGet().getPath());
						putQueryParameter("Container." + (depth1 + 1) + ".ReadinessProbe.HttpGet.Port" , containers.get(depth1).getReadinessProbe().getHttpGet().getPort());
						putQueryParameter("Container." + (depth1 + 1) + ".ReadinessProbe.HttpGet.Scheme" , containers.get(depth1).getReadinessProbe().getHttpGet().getScheme());
					}
					if(containers.get(depth1).getReadinessProbe().getTcpSocketPort() != null){
						putQueryParameter("Container." + (depth1 + 1) + ".ReadinessProbe.TcpSocket.Port" , containers.get(depth1).getReadinessProbe().getTcpSocketPort());
					}

					putQueryParameter("Container." + (depth1 + 1) + ".ReadinessProbe.InitialDelaySeconds" , containers.get(depth1).getReadinessProbe().getInitialDelaySeconds());
					putQueryParameter("Container." + (depth1 + 1) + ".ReadinessProbe.PeriodSeconds" , containers.get(depth1).getReadinessProbe().getPeriodSeconds());
					putQueryParameter("Container." + (depth1 + 1) + ".ReadinessProbe.SuccessThreshold" , containers.get(depth1).getReadinessProbe().getSuccessThreshold());
					putQueryParameter("Container." + (depth1 + 1) + ".ReadinessProbe.FailureThreshold" , containers.get(depth1).getReadinessProbe().getFailureThreshold());
					putQueryParameter("Container." + (depth1 + 1) + ".ReadinessProbe.TimeoutSeconds" , containers.get(depth1).getReadinessProbe().getTimeoutSeconds());
				}

				if(containers.get(depth1).getLivenessProbe() != null){
					if(containers.get(depth1).getLivenessProbe().getExec() != null){
						for (int i = 0; i < containers.get(depth1).getLivenessProbe().getExec().size(); i++) {
							putQueryParameter("Container." + (depth1 + 1) + ".LivenessProbe.Exec.Command." + (i + 1) , containers.get(depth1).getLivenessProbe().getExec().get(i));
						}
					}
					if(containers.get(depth1).getLivenessProbe().getHttpGet() != null){
						putQueryParameter("Container." + (depth1 + 1) + ".LivenessProbe.HttpGet.Path" , containers.get(depth1).getLivenessProbe().getHttpGet().getPath());
						putQueryParameter("Container." + (depth1 + 1) + ".LivenessProbe.HttpGet.Port" , containers.get(depth1).getLivenessProbe().getHttpGet().getPort());
						putQueryParameter("Container." + (depth1 + 1) + ".LivenessProbe.HttpGet.Scheme" , containers.get(depth1).getLivenessProbe().getHttpGet().getScheme());
					}
					if(containers.get(depth1).getLivenessProbe().getTcpSocketPort() != null){
						putQueryParameter("Container." + (depth1 + 1) + ".LivenessProbe.TcpSocket.Port" , containers.get(depth1).getLivenessProbe().getTcpSocketPort());
					}

					putQueryParameter("Container." + (depth1 + 1) + ".LivenessProbe.InitialDelaySeconds" , containers.get(depth1).getLivenessProbe().getInitialDelaySeconds());
					putQueryParameter("Container." + (depth1 + 1) + ".LivenessProbe.PeriodSeconds" , containers.get(depth1).getLivenessProbe().getPeriodSeconds());
					putQueryParameter("Container." + (depth1 + 1) + ".LivenessProbe.SuccessThreshold" , containers.get(depth1).getLivenessProbe().getSuccessThreshold());
					putQueryParameter("Container." + (depth1 + 1) + ".LivenessProbe.FailureThreshold" , containers.get(depth1).getLivenessProbe().getFailureThreshold());
					putQueryParameter("Container." + (depth1 + 1) + ".LivenessProbe.TimeoutSeconds" , containers.get(depth1).getLivenessProbe().getTimeoutSeconds());
				}

				if(containers.get(depth1).getSecurityContext() != null){
					if (containers.get(depth1).getSecurityContext().getCapability() != null) {
						if(containers.get(depth1).getSecurityContext().getCapability().getAdds() != null){
							for (int i = 0; i < containers.get(depth1).getSecurityContext().getCapability().getAdds().size(); i++) {
								putQueryParameter("Container." + (depth1 + 1) + ".SecurityContext.Capability.Add." + (i + 1) , containers.get(depth1).getSecurityContext().getCapability().getAdds().get(i));
							}
						}

					}
					putQueryParameter("Container." + (depth1 + 1) + ".SecurityContext.ReadOnlyRootFilesystem" , containers.get(depth1).getSecurityContext().getReadOnlyRootFilesystem());
					putQueryParameter("Container." + (depth1 + 1) + ".SecurityContext.RunAsUser" , containers.get(depth1).getSecurityContext().getRunAsUser());
				}
			}
		}
	}