org.apache.kafka.common.protocol
Enum ApiKeys
java.lang.Object
java.lang.Enum<ApiKeys>
org.apache.kafka.common.protocol.ApiKeys
- All Implemented Interfaces:
- java.io.Serializable, java.lang.Comparable<ApiKeys>
public enum ApiKeys
- extends java.lang.Enum<ApiKeys>
Identifiers for all the Kafka APIs
Field Summary |
short |
id
the perminant and immutable id of an API--this can't change ever |
static int |
MAX_API_KEY
|
java.lang.String |
name
an english description of the api--this is for debugging and can change |
Method Summary |
static ApiKeys |
forId(int id)
|
static ApiKeys |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. |
static ApiKeys[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared. |
Methods inherited from class java.lang.Enum |
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf |
Methods inherited from class java.lang.Object |
getClass, notify, notifyAll, wait, wait, wait |
PRODUCE
public static final ApiKeys PRODUCE
FETCH
public static final ApiKeys FETCH
LIST_OFFSETS
public static final ApiKeys LIST_OFFSETS
METADATA
public static final ApiKeys METADATA
LEADER_AND_ISR
public static final ApiKeys LEADER_AND_ISR
STOP_REPLICA
public static final ApiKeys STOP_REPLICA
OFFSET_COMMIT
public static final ApiKeys OFFSET_COMMIT
OFFSET_FETCH
public static final ApiKeys OFFSET_FETCH
CONSUMER_METADATA
public static final ApiKeys CONSUMER_METADATA
JOIN_GROUP
public static final ApiKeys JOIN_GROUP
HEARTBEAT
public static final ApiKeys HEARTBEAT
MAX_API_KEY
public static int MAX_API_KEY
id
public final short id
- the perminant and immutable id of an API--this can't change ever
name
public final java.lang.String name
- an english description of the api--this is for debugging and can change
values
public static ApiKeys[] values()
- Returns an array containing the constants of this enum type, in
the order they are declared. This method may be used to iterate
over the constants as follows:
for (ApiKeys c : ApiKeys.values())
System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in
the order they are declared
valueOf
public static ApiKeys valueOf(java.lang.String name)
- Returns the enum constant of this type with the specified name.
The string must match exactly an identifier used to declare an
enum constant in this type. (Extraneous whitespace characters are
not permitted.)
- Parameters:
name
- the name of the enum constant to be returned.
- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant
with the specified name
java.lang.NullPointerException
- if the argument is null
forId
public static ApiKeys forId(int id)