public abstract class Channel extends java.lang.Object implements java.lang.Comparable<Channel>
| Modifier and Type | Field and Description |
|---|---|
static Channel |
DEFAULT
The default channel is the most stable.
|
| Constructor and Description |
|---|
Channel() |
| Modifier and Type | Method and Description |
|---|---|
int |
compareTo(Channel o) |
static Channel |
create(int id)
Create a new
Channel with the specified ID. |
boolean |
equals(java.lang.Object obj) |
java.lang.String |
getDisplayName()
Gets the display name for this channel.
|
abstract java.lang.String |
getId()
Gets the string ID for this channel, in the format
channel-N. |
protected abstract java.lang.String |
getValue()
Gets the (possibly null) display name for this channel.
|
int |
hashCode() |
abstract void |
setId(java.lang.String id)
Sets the string ID for this channel.
|
abstract void |
setValue(java.lang.String displayName)
Sets the displayName for this channel.
|
public static final Channel DEFAULT
@NonNull public static Channel create(int id)
Channel with the specified ID.id - The id of the channel. If this channel will ever be marshalled the
value must be between 0 and 9 or the xml will fail validation.@Nullable protected abstract java.lang.String getValue()
public abstract void setValue(@Nullable
java.lang.String displayName)
@NonNull public java.lang.String getDisplayName()
channel-N) is returned.@NonNull public abstract java.lang.String getId()
channel-N.public abstract void setId(@NonNull
java.lang.String id)
public int compareTo(Channel o)
compareTo in interface java.lang.Comparable<Channel>public boolean equals(java.lang.Object obj)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Object