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

com.arm.mbed.cloud.sdk.devices.model.DeviceEnrollmentBulkCreateStatus Maven / Gradle / Ivy

Go to download

The Pelion Cloud SDK (formerly known as Mbed Cloud SDK) provides a simplified interface to the Pelion Cloud APIs by exposing functionality using conventions and paradigms familiar to Java developers.

There is a newer version: 2.5.0
Show newest version
// This file was generated by the Pelion SDK foundation code generator.
// This is an autogenerated class. Do not modify its content as modifications will be lost at next code generation.
package com.arm.mbed.cloud.sdk.devices.model;

import com.arm.mbed.cloud.sdk.annotations.DefaultValue;
import com.arm.mbed.cloud.sdk.annotations.Internal;
import com.arm.mbed.cloud.sdk.annotations.Preamble;
import com.arm.mbed.cloud.sdk.annotations.Required;
import com.arm.mbed.cloud.sdk.common.SdkEnum;

/**
 * Device enrollment bulk create status.
 */
@Preamble(description = "Device enrollment bulk create status.")
public enum DeviceEnrollmentBulkCreateStatus implements SdkEnum {
    COMPLETED("completed"),

    NEW("new"),

    PROCESSING("processing"),

    UNKNOWN_ENUM(SDK_UNKNOWN_ENUM_VALUE);

    /**
     * Serialisation Id.
     */
    private static final long serialVersionUID = -425308309452293L;

    /**
     * string representation.
     */
    @Internal
    @Required
    @DefaultValue("COMPLETED")
    private final String string;

    /**
     * Internal constructor.
     * 
     * @param string
     *            string representation.
     */
    @Internal
    DeviceEnrollmentBulkCreateStatus(@DefaultValue("COMPLETED") String string) {
        this.string = string;
    }

    /**
     * Gets string representation.
     * 
     * @return string
     */
    @Override
    @Internal
    public String getString() {
        return string;
    }

    /**
     * toString.
     *
     * 

* * @see java.lang.Enum#toString() * @return the string representation of this value */ @Override public String toString() { return getString(); } /** * States whether it is the default value. * *

* * @see SdkEnum#isDefault() * @return true if this is the default value; false otherwise */ @Override public boolean isDefault() { return this == getDefault(); } /** * States whether the value is unknown and an error happened during parsing. * *

* * @see SdkEnum#isUnknownValue() * @return true if this is an unknown value; false otherwise */ @Override public boolean isUnknownValue() { return this == getUnknownEnum(); } /** * Gets default device enrollment bulk create status. * * @return default device enrollment bulk create status */ public static DeviceEnrollmentBulkCreateStatus getDefault() { return COMPLETED; } /** * Gets unknown device enrollment bulk create status value. * * @return unknown device enrollment bulk create status */ public static DeviceEnrollmentBulkCreateStatus getUnknownEnum() { return UNKNOWN_ENUM; } /** * Gets device enrollment bulk create status from its string representation. * * @param value * string. * @return corresponding device enrollment bulk create status or default device enrollment bulk create status if not * recognised. */ public static DeviceEnrollmentBulkCreateStatus getValue(String value) { if (value == null) { return getDefault(); } final String trimmedValue = value.trim(); for (final DeviceEnrollmentBulkCreateStatus option : values()) { if (option.getString().equalsIgnoreCase(trimmedValue)) { return option; } } return getDefault(); } /** * Merges two states. * *

* * @see SdkEnum#merge(SdkEnum, SdkEnum) * @param * type of an sdk enum * @param obj1 * a device enrollment bulk create status. * @param obj2 * a device enrollment bulk create status. * @return the merged enumerator */ @Override public T merge(T obj1, T obj2) { if (obj1 == null) { return obj2; } if (obj2 == null) { return obj1; } if (obj1.isDefault()) { return obj2; } if (obj2.isDefault()) { return obj1; } return obj2; } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy