io.nem.sdk.openapi.jersey2.model.AccountRestrictionFlagsEnum Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of api-jersey2-client Show documentation
Show all versions of api-jersey2-client Show documentation
Generated Open API client for NEM
/*
* Catapult REST Endpoints
* OpenAPI Specification of catapult-rest 1.0.20.10
*
* The version of the OpenAPI document: 0.8.2
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
package io.nem.sdk.openapi.jersey2.model;
import java.util.Objects;
import java.util.Arrays;
import io.swagger.annotations.ApiModel;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonValue;
/**
* Type of account restriction: * 0x0001 (1 decimal) - Allow only incoming transactions from a given address. * 0x0002 (2 decimal) - Allow only incoming transactions containing a given mosaic identifier. * 0x4001 (16385 decimal) - Allow only outgoing transactions to a given address. * 0x4004 (16388 decimal) - Allow only outgoing transactions with a given transaction type. * 0x8001 (32769 decimal) - Block incoming transactions from a given address. * 0x8002 (32770 decimal) - Block incoming transactions containing a given mosaic identifier. * 0xC001 (49153 decimal) - Block outgoing transactions to a given address. * 0xC004 (49156 decimal) - Block outgoing transactions with a given transaction type.
*/
public enum AccountRestrictionFlagsEnum {
NUMBER_1(1),
NUMBER_2(2),
NUMBER_16385(16385),
NUMBER_16388(16388),
NUMBER_32769(32769),
NUMBER_32770(32770),
NUMBER_49153(49153),
NUMBER_49156(49156);
private Integer value;
AccountRestrictionFlagsEnum(Integer value) {
this.value = value;
}
@JsonValue
public Integer getValue() {
return value;
}
@Override
public String toString() {
return String.valueOf(value);
}
@JsonCreator
public static AccountRestrictionFlagsEnum fromValue(Integer value) {
for (AccountRestrictionFlagsEnum b : AccountRestrictionFlagsEnum.values()) {
if (b.value.equals(value)) {
return b;
}
}
throw new IllegalArgumentException("Unexpected value '" + value + "'");
}
}