public final class DhcpErrorEvent extends Object implements Parcelable
Parcelable.ClassLoaderCreator<T>, Parcelable.Creator<T>
Modifier and Type | Field and Description |
---|---|
static int |
BOOTP_TOO_SHORT |
static int |
BUFFER_UNDERFLOW |
static Parcelable.Creator<DhcpErrorEvent> |
CREATOR |
static int |
DHCP_BAD_MAGIC_COOKIE |
static int |
DHCP_ERROR |
static int |
DHCP_INVALID_OPTION_LENGTH |
static int |
DHCP_NO_COOKIE |
static int |
DHCP_NO_MSG_TYPE |
static int |
DHCP_UNKNOWN_MSG_TYPE |
int |
errorCode |
String |
ifName |
static int |
L2_ERROR |
static int |
L2_TOO_SHORT |
static int |
L2_WRONG_ETH_TYPE |
static int |
L3_ERROR |
static int |
L3_INVALID_IP |
static int |
L3_NOT_IPV4 |
static int |
L3_TOO_SHORT |
static int |
L4_ERROR |
static int |
L4_NOT_UDP |
static int |
L4_WRONG_PORT |
static int |
MISC_ERROR |
static int |
PARSING_ERROR |
static int |
RECEIVE_ERROR |
CONTENTS_FILE_DESCRIPTOR, PARCELABLE_ELIDE_DUPLICATES, PARCELABLE_WRITE_RETURN_VALUE
Constructor and Description |
---|
DhcpErrorEvent(String ifName,
int errorCode) |
Modifier and Type | Method and Description |
---|---|
int |
describeContents()
Describe the kinds of special objects contained in this Parcelable
instance's marshaled representation.
|
static int |
errorCodeWithOption(int errorCode,
int option) |
static void |
logParseError(String ifName,
int errorCode) |
static void |
logReceiveError(String ifName) |
String |
toString()
Returns a string representation of the object.
|
void |
writeToParcel(Parcel out,
int flags)
Flatten this object in to a Parcel.
|
public static final int L2_ERROR
public static final int L3_ERROR
public static final int L4_ERROR
public static final int DHCP_ERROR
public static final int MISC_ERROR
public static final int L2_TOO_SHORT
public static final int L2_WRONG_ETH_TYPE
public static final int L3_TOO_SHORT
public static final int L3_NOT_IPV4
public static final int L3_INVALID_IP
public static final int L4_NOT_UDP
public static final int L4_WRONG_PORT
public static final int BOOTP_TOO_SHORT
public static final int DHCP_BAD_MAGIC_COOKIE
public static final int DHCP_INVALID_OPTION_LENGTH
public static final int DHCP_NO_MSG_TYPE
public static final int DHCP_UNKNOWN_MSG_TYPE
public static final int DHCP_NO_COOKIE
public static final int BUFFER_UNDERFLOW
public static final int RECEIVE_ERROR
public static final int PARSING_ERROR
public final String ifName
public final int errorCode
public static final Parcelable.Creator<DhcpErrorEvent> CREATOR
public DhcpErrorEvent(String ifName, int errorCode)
public void writeToParcel(Parcel out, int flags)
Parcelable
writeToParcel
in interface Parcelable
out
- The Parcel in which the object should be written.flags
- Additional flags about how the object should be written.
May be 0 or Parcelable.PARCELABLE_WRITE_RETURN_VALUE
.public int describeContents()
Parcelable
Parcelable.writeToParcel(Parcel, int)
,
the return value of this method must include the
Parcelable.CONTENTS_FILE_DESCRIPTOR
bit.describeContents
in interface Parcelable
Parcelable.CONTENTS_FILE_DESCRIPTOR
public static void logParseError(String ifName, int errorCode)
public static void logReceiveError(String ifName)
public static int errorCodeWithOption(int errorCode, int option)
public String toString()
Object
toString
method returns a string that
"textually represents" this object. The result should
be a concise but informative representation that is easy for a
person to read.
It is recommended that all subclasses override this method.
The toString
method for class Object
returns a string consisting of the name of the class of which the
object is an instance, the at-sign character `@
', and
the unsigned hexadecimal representation of the hash code of the
object. In other words, this method returns a string equal to the
value of:
getClass().getName() + '@' + Integer.toHexString(hashCode())