📄 time_msg.java
字号:
/** * This class is automatically generated by mig. DO NOT EDIT THIS FILE. * This class implements a Java interface to the 'time_msg' * message type. */public class time_msg extends net.tinyos.message.Message { /** The default size of this message type in bytes. */ public static final int DEFAULT_MESSAGE_SIZE = 6; /** The Active Message type associated with this message. */ public static final int AM_TYPE = 13; /** Create a new time_msg of size 6. */ public time_msg() { super(DEFAULT_MESSAGE_SIZE); amTypeSet(AM_TYPE); } /** Create a new time_msg of the given data_length. */ public time_msg(int data_length) { super(data_length); amTypeSet(AM_TYPE); } /** * Create a new time_msg with the given data_length * and base offset. */ public time_msg(int data_length, int base_offset) { super(data_length, base_offset); amTypeSet(AM_TYPE); } /** * Create a new time_msg using the given byte array * as backing store. */ public time_msg(byte[] data) { super(data); amTypeSet(AM_TYPE); } /** * Create a new time_msg using the given byte array * as backing store, with the given base offset. */ public time_msg(byte[] data, int base_offset) { super(data, base_offset); amTypeSet(AM_TYPE); } /** * Create a new time_msg using the given byte array * as backing store, with the given base offset and data length. */ public time_msg(byte[] data, int base_offset, int data_length) { super(data, base_offset, data_length); amTypeSet(AM_TYPE); } /** * Create a new time_msg embedded in the given message * at the given base offset. */ public time_msg(net.tinyos.message.Message msg, int base_offset) { super(msg, base_offset, DEFAULT_MESSAGE_SIZE); amTypeSet(AM_TYPE); } /** * Create a new time_msg embedded in the given message * at the given base offset and length. */ public time_msg(net.tinyos.message.Message msg, int base_offset, int data_length) { super(msg, base_offset, data_length); amTypeSet(AM_TYPE); } /** /* Return a String representation of this message. Includes the * message type name and the non-indexed field values. */ public String toString() { String s = "Message <time_msg> \n"; try { s += " [t=0x"+Long.toHexString(get_t())+"]\n"; } catch (ArrayIndexOutOfBoundsException aioobe) { /* Skip field */ } try { s += " [type=0x"+Long.toHexString(get_type())+"]\n"; } catch (ArrayIndexOutOfBoundsException aioobe) { /* Skip field */ } try { s += " [pass=0x"+Long.toHexString(get_pass())+"]\n"; } catch (ArrayIndexOutOfBoundsException aioobe) { /* Skip field */ } return s; } // Message-type-specific access methods appear below. ///////////////////////////////////////////////////////// // Accessor methods for field: t // Field type: long, unsigned // Offset (bits): 0 // Size (bits): 32 ///////////////////////////////////////////////////////// /** * Return whether the field 't' is signed (false). */ public static boolean isSigned_t() { return false; } /** * Return whether the field 't' is an array (false). */ public static boolean isArray_t() { return false; } /** * Return the offset (in bytes) of the field 't' */ public static int offset_t() { return (0 / 8); } /** * Return the offset (in bits) of the field 't' */ public static int offsetBits_t() { return 0; } /** * Return the value (as a long) of the field 't' */ public long get_t() { return (long)getUIntElement(offsetBits_t(), 32); } /** * Set the value of the field 't' */ public void set_t(long value) { setUIntElement(offsetBits_t(), 32, value); } /** * Return the size, in bytes, of the field 't' */ public static int size_t() { return (32 / 8); } /** * Return the size, in bits, of the field 't' */ public static int sizeBits_t() { return 32; } ///////////////////////////////////////////////////////// // Accessor methods for field: type // Field type: short, unsigned // Offset (bits): 32 // Size (bits): 8 ///////////////////////////////////////////////////////// /** * Return whether the field 'type' is signed (false). */ public static boolean isSigned_type() { return false; } /** * Return whether the field 'type' is an array (false). */ public static boolean isArray_type() { return false; } /** * Return the offset (in bytes) of the field 'type' */ public static int offset_type() { return (32 / 8); } /** * Return the offset (in bits) of the field 'type' */ public static int offsetBits_type() { return 32; } /** * Return the value (as a short) of the field 'type' */ public short get_type() { return (short)getUIntElement(offsetBits_type(), 8); } /** * Set the value of the field 'type' */ public void set_type(short value) { setUIntElement(offsetBits_type(), 8, value); } /** * Return the size, in bytes, of the field 'type' */ public static int size_type() { return (8 / 8); } /** * Return the size, in bits, of the field 'type' */ public static int sizeBits_type() { return 8; } ///////////////////////////////////////////////////////// // Accessor methods for field: pass // Field type: short, unsigned // Offset (bits): 40 // Size (bits): 8 ///////////////////////////////////////////////////////// /** * Return whether the field 'pass' is signed (false). */ public static boolean isSigned_pass() { return false; } /** * Return whether the field 'pass' is an array (false). */ public static boolean isArray_pass() { return false; } /** * Return the offset (in bytes) of the field 'pass' */ public static int offset_pass() { return (40 / 8); } /** * Return the offset (in bits) of the field 'pass' */ public static int offsetBits_pass() { return 40; } /** * Return the value (as a short) of the field 'pass' */ public short get_pass() { return (short)getUIntElement(offsetBits_pass(), 8); } /** * Set the value of the field 'pass' */ public void set_pass(short value) { setUIntElement(offsetBits_pass(), 8, value); } /** * Return the size, in bytes, of the field 'pass' */ public static int size_pass() { return (8 / 8); } /** * Return the size, in bits, of the field 'pass' */ public static int sizeBits_pass() { return 8; }}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -