Public Member Functions | Private Attributes

scsi_Wrapper24 Class Reference
[SCSI Library]

Class thatis a wrapper around scsi_UInt24_t and behaves like a 24-bit integer. More...

#include <scsi_types.h>

List of all members.

Public Member Functions

 scsi_Wrapper24 ()
 scsi_Wrapper24 (UInt32_t a_uint)
 scsi_Wrapper24 (scsi_UInt24_t &a_buf)
scsi_Wrapper24operator= (UInt32_t a_uint)
scsi_Wrapper24operator= (scsi_UInt24_t &a_buf)
 operator UInt32_t () const

Private Attributes

scsi_UInt24_tm_data_p

Detailed Description

Class thatis a wrapper around scsi_UInt24_t and behaves like a 24-bit integer.

Definition at line 198 of file scsi_types.h.


Constructor & Destructor Documentation

scsi_Wrapper24::scsi_Wrapper24 (  )  [inline]

Definition at line 200 of file scsi_types.h.

                            : m_data_p(NULL) {
    };

scsi_Wrapper24::scsi_Wrapper24 ( UInt32_t  a_uint  )  [inline, explicit]

Definition at line 203 of file scsi_types.h.

                                                    {
        scsi_UInt32_t* buf = reinterpret_cast<scsi_UInt32_t*>(&a_uint);
        (*m_data_p)[0] = (*buf)[0],
        (*m_data_p)[1] = (*buf)[1],
        (*m_data_p)[2] = (*buf)[2];
    };

scsi_Wrapper24::scsi_Wrapper24 ( scsi_UInt24_t a_buf  )  [inline]

Definition at line 210 of file scsi_types.h.

                                                : m_data_p(&a_buf) {
        // Empty
    };


Member Function Documentation

scsi_Wrapper24::operator UInt32_t (  )  const [inline]

Definition at line 227 of file scsi_types.h.

                                      {
        UInt32_t retval = *(reinterpret_cast<const UInt32_t*>(*m_data_p));
        return (retval & 0x00FFFFFF);
    };

scsi_Wrapper24& scsi_Wrapper24::operator= ( UInt32_t  a_uint  )  [inline]

Definition at line 214 of file scsi_types.h.

                                                        {
        scsi_UInt32_t* buf = reinterpret_cast<scsi_UInt32_t*>(&a_uint);
        (*m_data_p)[0] = (*buf)[0],
        (*m_data_p)[1] = (*buf)[1],
        (*m_data_p)[2] = (*buf)[2];
        return (*this);
    };

scsi_Wrapper24& scsi_Wrapper24::operator= ( scsi_UInt24_t a_buf  )  [inline]

Definition at line 222 of file scsi_types.h.

                                                             {
        m_data_p = &a_buf;
        return (*this);
    };


Member Data Documentation

Definition at line 230 of file scsi_types.h.


The documentation for this class was generated from the following file: