All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.amazonaws.services.greengrassv2.model.ComponentRunWith Maven / Gradle / Ivy

/*
 * Copyright 2016-2021 Amazon.com, Inc. or its affiliates. All Rights Reserved.
 * 
 * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with
 * the License. A copy of the License is located at
 * 
 * http://aws.amazon.com/apache2.0
 * 
 * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
 * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions
 * and limitations under the License.
 */
package com.amazonaws.services.greengrassv2.model;

import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.protocol.StructuredPojo;
import com.amazonaws.protocol.ProtocolMarshaller;

/**
 * 

* Contains information system user and group that the IoT Greengrass Core software uses to run component processes on * the core device. For more information, see Configure the user and group that run components in the IoT Greengrass V2 Developer Guide. *

* * @see AWS API * Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class ComponentRunWith implements Serializable, Cloneable, StructuredPojo { /** *

* The POSIX system user and (optional) group to use to run this component. Specify the user and group separated by * a colon (:) in the following format: user:group. The group is optional. If you don't * specify a group, the IoT Greengrass Core software uses the primary user for the group. *

*

* If you omit this parameter, the IoT Greengrass Core software uses the default system user and group that you * configure on the Greengrass nucleus component. For more information, see Configure the user and group that run components. *

*/ private String posixUser; /** *

* The system resource limits to apply to this component's process on the core device. *

*

* If you omit this parameter, the IoT Greengrass Core software uses the default system resource limits that you * configure on the Greengrass nucleus component. For more information, see Configure system resource limits for components. *

*/ private SystemResourceLimits systemResourceLimits; /** *

* The POSIX system user and (optional) group to use to run this component. Specify the user and group separated by * a colon (:) in the following format: user:group. The group is optional. If you don't * specify a group, the IoT Greengrass Core software uses the primary user for the group. *

*

* If you omit this parameter, the IoT Greengrass Core software uses the default system user and group that you * configure on the Greengrass nucleus component. For more information, see Configure the user and group that run components. *

* * @param posixUser * The POSIX system user and (optional) group to use to run this component. Specify the user and group * separated by a colon (:) in the following format: user:group. The group is * optional. If you don't specify a group, the IoT Greengrass Core software uses the primary user for the * group.

*

* If you omit this parameter, the IoT Greengrass Core software uses the default system user and group that * you configure on the Greengrass nucleus component. For more information, see Configure the user and group that run components. */ public void setPosixUser(String posixUser) { this.posixUser = posixUser; } /** *

* The POSIX system user and (optional) group to use to run this component. Specify the user and group separated by * a colon (:) in the following format: user:group. The group is optional. If you don't * specify a group, the IoT Greengrass Core software uses the primary user for the group. *

*

* If you omit this parameter, the IoT Greengrass Core software uses the default system user and group that you * configure on the Greengrass nucleus component. For more information, see Configure the user and group that run components. *

* * @return The POSIX system user and (optional) group to use to run this component. Specify the user and group * separated by a colon (:) in the following format: user:group. The group is * optional. If you don't specify a group, the IoT Greengrass Core software uses the primary user for the * group.

*

* If you omit this parameter, the IoT Greengrass Core software uses the default system user and group that * you configure on the Greengrass nucleus component. For more information, see Configure the user and group that run components. */ public String getPosixUser() { return this.posixUser; } /** *

* The POSIX system user and (optional) group to use to run this component. Specify the user and group separated by * a colon (:) in the following format: user:group. The group is optional. If you don't * specify a group, the IoT Greengrass Core software uses the primary user for the group. *

*

* If you omit this parameter, the IoT Greengrass Core software uses the default system user and group that you * configure on the Greengrass nucleus component. For more information, see Configure the user and group that run components. *

* * @param posixUser * The POSIX system user and (optional) group to use to run this component. Specify the user and group * separated by a colon (:) in the following format: user:group. The group is * optional. If you don't specify a group, the IoT Greengrass Core software uses the primary user for the * group.

*

* If you omit this parameter, the IoT Greengrass Core software uses the default system user and group that * you configure on the Greengrass nucleus component. For more information, see Configure the user and group that run components. * @return Returns a reference to this object so that method calls can be chained together. */ public ComponentRunWith withPosixUser(String posixUser) { setPosixUser(posixUser); return this; } /** *

* The system resource limits to apply to this component's process on the core device. *

*

* If you omit this parameter, the IoT Greengrass Core software uses the default system resource limits that you * configure on the Greengrass nucleus component. For more information, see Configure system resource limits for components. *

* * @param systemResourceLimits * The system resource limits to apply to this component's process on the core device.

*

* If you omit this parameter, the IoT Greengrass Core software uses the default system resource limits that * you configure on the Greengrass nucleus component. For more information, see Configure system resource limits for components. */ public void setSystemResourceLimits(SystemResourceLimits systemResourceLimits) { this.systemResourceLimits = systemResourceLimits; } /** *

* The system resource limits to apply to this component's process on the core device. *

*

* If you omit this parameter, the IoT Greengrass Core software uses the default system resource limits that you * configure on the Greengrass nucleus component. For more information, see Configure system resource limits for components. *

* * @return The system resource limits to apply to this component's process on the core device.

*

* If you omit this parameter, the IoT Greengrass Core software uses the default system resource limits that * you configure on the Greengrass nucleus component. For more information, see Configure system resource limits for components. */ public SystemResourceLimits getSystemResourceLimits() { return this.systemResourceLimits; } /** *

* The system resource limits to apply to this component's process on the core device. *

*

* If you omit this parameter, the IoT Greengrass Core software uses the default system resource limits that you * configure on the Greengrass nucleus component. For more information, see Configure system resource limits for components. *

* * @param systemResourceLimits * The system resource limits to apply to this component's process on the core device.

*

* If you omit this parameter, the IoT Greengrass Core software uses the default system resource limits that * you configure on the Greengrass nucleus component. For more information, see Configure system resource limits for components. * @return Returns a reference to this object so that method calls can be chained together. */ public ComponentRunWith withSystemResourceLimits(SystemResourceLimits systemResourceLimits) { setSystemResourceLimits(systemResourceLimits); return this; } /** * Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be * redacted from this string using a placeholder value. * * @return A string representation of this object. * * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getPosixUser() != null) sb.append("PosixUser: ").append(getPosixUser()).append(","); if (getSystemResourceLimits() != null) sb.append("SystemResourceLimits: ").append(getSystemResourceLimits()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof ComponentRunWith == false) return false; ComponentRunWith other = (ComponentRunWith) obj; if (other.getPosixUser() == null ^ this.getPosixUser() == null) return false; if (other.getPosixUser() != null && other.getPosixUser().equals(this.getPosixUser()) == false) return false; if (other.getSystemResourceLimits() == null ^ this.getSystemResourceLimits() == null) return false; if (other.getSystemResourceLimits() != null && other.getSystemResourceLimits().equals(this.getSystemResourceLimits()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getPosixUser() == null) ? 0 : getPosixUser().hashCode()); hashCode = prime * hashCode + ((getSystemResourceLimits() == null) ? 0 : getSystemResourceLimits().hashCode()); return hashCode; } @Override public ComponentRunWith clone() { try { return (ComponentRunWith) super.clone(); } catch (CloneNotSupportedException e) { throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e); } } @com.amazonaws.annotation.SdkInternalApi @Override public void marshall(ProtocolMarshaller protocolMarshaller) { com.amazonaws.services.greengrassv2.model.transform.ComponentRunWithMarshaller.getInstance().marshall(this, protocolMarshaller); } }





© 2015 - 2025 Weber Informatics LLC | Privacy Policy