⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 s4reverselinkmessage.java

📁 state strech routing protocl
💻 JAVA
📖 第 1 页 / 共 2 页
字号:
/** * This class is automatically generated by mig. DO NOT EDIT THIS FILE. * This class implements a Java interface to the 'S4ReverseLinkMessage' * message type. */package net.tinyos.cr.messages;public class S4ReverseLinkMessage extends net.tinyos.message.Message {    /** The default size of this message type in bytes. */    public static final int DEFAULT_MESSAGE_SIZE = 27;    /** The Active Message type associated with this message. */    public static final int AM_TYPE = 59;    /** Create a new S4ReverseLinkMessage of size 27. */    public S4ReverseLinkMessage() {        super(DEFAULT_MESSAGE_SIZE);        amTypeSet(AM_TYPE);    }    /** Create a new S4ReverseLinkMessage of the given data_length. */    public S4ReverseLinkMessage(int data_length) {        super(data_length);        amTypeSet(AM_TYPE);    }    /**     * Create a new S4ReverseLinkMessage with the given data_length     * and base offset.     */    public S4ReverseLinkMessage(int data_length, int base_offset) {        super(data_length, base_offset);        amTypeSet(AM_TYPE);    }    /**     * Create a new S4ReverseLinkMessage using the given byte array     * as backing store.     */    public S4ReverseLinkMessage(byte[] data) {        super(data);        amTypeSet(AM_TYPE);    }    /**     * Create a new S4ReverseLinkMessage using the given byte array     * as backing store, with the given base offset.     */    public S4ReverseLinkMessage(byte[] data, int base_offset) {        super(data, base_offset);        amTypeSet(AM_TYPE);    }    /**     * Create a new S4ReverseLinkMessage using the given byte array     * as backing store, with the given base offset and data length.     */    public S4ReverseLinkMessage(byte[] data, int base_offset, int data_length) {        super(data, base_offset, data_length);        amTypeSet(AM_TYPE);    }    /**     * Create a new S4ReverseLinkMessage embedded in the given message     * at the given base offset.     */    public S4ReverseLinkMessage(net.tinyos.message.Message msg, int base_offset) {        super(msg, base_offset, DEFAULT_MESSAGE_SIZE);        amTypeSet(AM_TYPE);    }    /**     * Create a new S4ReverseLinkMessage embedded in the given message     * at the given base offset and length.     */    public S4ReverseLinkMessage(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 <S4ReverseLinkMessage> \n";      try {        s += "  [header.last_hop=0x"+Long.toHexString(get_header_last_hop())+"]\n";      } catch (ArrayIndexOutOfBoundsException aioobe) { /* Skip field */ }      try {        s += "  [header.seqno=0x"+Long.toHexString(get_header_seqno())+"]\n";      } catch (ArrayIndexOutOfBoundsException aioobe) { /* Skip field */ }      try {        s += "  [info.num_elements=0x"+Long.toHexString(get_info_num_elements())+"]\n";      } catch (ArrayIndexOutOfBoundsException aioobe) { /* Skip field */ }      try {        s += "  [info.total_links=0x"+Long.toHexString(get_info_total_links())+"]\n";      } catch (ArrayIndexOutOfBoundsException aioobe) { /* Skip field */ }      try {        s += "  [info.entries.addr=";        for (int i = 0; i < 7; i++) {          s += "0x"+Long.toHexString(getElement_info_entries_addr(i) & 0xff)+" ";        }        s += "]\n";      } catch (ArrayIndexOutOfBoundsException aioobe) { /* Skip field */ }      try {        s += "  [info.entries.quality=";        for (int i = 0; i < 7; i++) {          s += "0x"+Long.toHexString(getElement_info_entries_quality(i) & 0xff)+" ";        }        s += "]\n";      } catch (ArrayIndexOutOfBoundsException aioobe) { /* Skip field */ }      return s;    }    // Message-type-specific access methods appear below.    /////////////////////////////////////////////////////////    // Accessor methods for field: header.last_hop    //   Field type: int    //   Offset (bits): 0    //   Size (bits): 16    /////////////////////////////////////////////////////////    /**     * Return whether the field 'header.last_hop' is signed (false).     */    public static boolean isSigned_header_last_hop() {        return false;    }    /**     * Return whether the field 'header.last_hop' is an array (false).     */    public static boolean isArray_header_last_hop() {        return false;    }    /**     * Return the offset (in bytes) of the field 'header.last_hop'     */    public static int offset_header_last_hop() {        return (0 / 8);    }    /**     * Return the offset (in bits) of the field 'header.last_hop'     */    public static int offsetBits_header_last_hop() {        return 0;    }    /**     * Return the value (as a int) of the field 'header.last_hop'     */    public int get_header_last_hop() {        return (int)getUIntElement(offsetBits_header_last_hop(), 16);    }    /**     * Set the value of the field 'header.last_hop'     */    public void set_header_last_hop(int value) {        setUIntElement(offsetBits_header_last_hop(), 16, value);    }    /**     * Return the size, in bytes, of the field 'header.last_hop'     */    public static int size_header_last_hop() {        return (16 / 8);    }    /**     * Return the size, in bits, of the field 'header.last_hop'     */    public static int sizeBits_header_last_hop() {        return 16;    }    /////////////////////////////////////////////////////////    // Accessor methods for field: header.seqno    //   Field type: int    //   Offset (bits): 16    //   Size (bits): 16    /////////////////////////////////////////////////////////    /**     * Return whether the field 'header.seqno' is signed (false).     */    public static boolean isSigned_header_seqno() {        return false;    }    /**     * Return whether the field 'header.seqno' is an array (false).     */    public static boolean isArray_header_seqno() {        return false;    }    /**     * Return the offset (in bytes) of the field 'header.seqno'     */    public static int offset_header_seqno() {        return (16 / 8);    }    /**     * Return the offset (in bits) of the field 'header.seqno'     */    public static int offsetBits_header_seqno() {        return 16;    }    /**     * Return the value (as a int) of the field 'header.seqno'     */    public int get_header_seqno() {        return (int)getUIntElement(offsetBits_header_seqno(), 16);    }    /**     * Set the value of the field 'header.seqno'     */    public void set_header_seqno(int value) {        setUIntElement(offsetBits_header_seqno(), 16, value);    }    /**     * Return the size, in bytes, of the field 'header.seqno'     */    public static int size_header_seqno() {        return (16 / 8);    }    /**     * Return the size, in bits, of the field 'header.seqno'     */    public static int sizeBits_header_seqno() {        return 16;    }    /////////////////////////////////////////////////////////    // Accessor methods for field: info.num_elements    //   Field type: short    //   Offset (bits): 32    //   Size (bits): 8    /////////////////////////////////////////////////////////    /**     * Return whether the field 'info.num_elements' is signed (false).     */    public static boolean isSigned_info_num_elements() {        return false;    }    /**     * Return whether the field 'info.num_elements' is an array (false).     */    public static boolean isArray_info_num_elements() {        return false;    }    /**     * Return the offset (in bytes) of the field 'info.num_elements'     */    public static int offset_info_num_elements() {        return (32 / 8);    }    /**     * Return the offset (in bits) of the field 'info.num_elements'     */    public static int offsetBits_info_num_elements() {        return 32;    }    /**     * Return the value (as a short) of the field 'info.num_elements'     */    public short get_info_num_elements() {        return (short)getUIntElement(offsetBits_info_num_elements(), 8);    }    /**     * Set the value of the field 'info.num_elements'     */    public void set_info_num_elements(short value) {        setUIntElement(offsetBits_info_num_elements(), 8, value);    }    /**     * Return the size, in bytes, of the field 'info.num_elements'     */    public static int size_info_num_elements() {        return (8 / 8);    }    /**     * Return the size, in bits, of the field 'info.num_elements'     */    public static int sizeBits_info_num_elements() {        return 8;    }    /////////////////////////////////////////////////////////    // Accessor methods for field: info.total_links    //   Field type: short    //   Offset (bits): 40    //   Size (bits): 8    /////////////////////////////////////////////////////////    /**     * Return whether the field 'info.total_links' is signed (false).     */    public static boolean isSigned_info_total_links() {        return false;    }    /**     * Return whether the field 'info.total_links' is an array (false).     */    public static boolean isArray_info_total_links() {        return false;

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -