internal static string ToSerializedValue(this AssetDtoValueScope value)
        {
            switch (value)
            {
            case AssetDtoValueScope.Global:
                return("Global");

            case AssetDtoValueScope.PerRobot:
                return("PerRobot");
            }
            return(null);
        }
 /// <summary>
 /// Initializes a new instance of the AssetDto class.
 /// </summary>
 /// <param name="name">A custom name for the asset.</param>
 /// <param name="valueScope">Defines the scope of the asset. Possible
 /// values include: 'Global', 'PerRobot'</param>
 /// <param name="canBeDeleted">States if an assets can be deleted. The
 /// default value of this property is true.</param>
 /// <param name="valueType">Defines the type of value stored by the
 /// asset. Possible values include: 'DBConnectionString',
 /// 'HttpConnectionString', 'Text', 'Bool', 'Integer', 'Credential',
 /// 'WindowsCredential', 'KeyValueList'</param>
 /// <param name="value">The textual representation of the asset value,
 /// irrespective of value type.</param>
 /// <param name="stringValue">The value of the asset when the value
 /// type is Text. Empty when the value type is not Text.</param>
 /// <param name="boolValue">The value of the asset when the value type
 /// is Bool. False when the value type is not Bool.</param>
 /// <param name="intValue">The value of the asset when the value type
 /// is Integer. 0 when the value type is not Integer.</param>
 /// <param name="credentialUsername">The user name when the value type
 /// is Credential. Empty when the value type is not Credential.</param>
 /// <param name="credentialPassword">The password when the value type
 /// is Credential. Empty when the value type is not Credential.</param>
 /// <param name="keyValueList">A collection of key value pairs when the
 /// type is KeyValueList. Empty when the value type is not
 /// KeyValueList.</param>
 /// <param name="robotValues">The collection of asset values per robot.
 /// Empty if the asset type is Global.</param>
 public AssetDto(string name, AssetDtoValueScope valueScope, bool?canBeDeleted = default(bool?), AssetDtoValueType?valueType = default(AssetDtoValueType?), string value = default(string), string stringValue = default(string), bool?boolValue = default(bool?), int?intValue = default(int?), string credentialUsername = default(string), string credentialPassword = default(string), IList <CustomKeyValuePair> keyValueList = default(IList <CustomKeyValuePair>), IList <AssetRobotValueDto> robotValues = default(IList <AssetRobotValueDto>), long?id = default(long?))
 {
     Name               = name;
     CanBeDeleted       = canBeDeleted;
     ValueScope         = valueScope;
     ValueType          = valueType;
     Value              = value;
     StringValue        = stringValue;
     BoolValue          = boolValue;
     IntValue           = intValue;
     CredentialUsername = credentialUsername;
     CredentialPassword = credentialPassword;
     KeyValueList       = keyValueList;
     RobotValues        = robotValues;
     Id = id;
     CustomInit();
 }