cdb_LogSelect Class Reference
[SCSI Library]

#include <cdb.h>

Inheritance diagram for cdb_LogSelect:

Inheritance graph
[legend]
Collaboration diagram for cdb_LogSelect:

Collaboration graph
[legend]

List of all members.


Detailed Description

SCSI Log Select command.

Definition at line 497 of file cdb.h.


Public Member Functions

 cdb_LogSelect (data_Log &a_log)
virtual ~cdb_LogSelect ()
virtual const UInt8_tGetCmdPointer () const
virtual UInt32_t GetCmdSize () const
virtual Direction_e GetTransferDirection () const
virtual UInt8_tGetBufferPointer () const
virtual UInt32_t GetBufferSize () const
const data_LogGetData () const

Private Attributes

 log_CLASSID_m
cdb_LogSelect_t m_logSelectCmd
data_Logm_data

Constructor & Destructor Documentation

cdb_LogSelect::cdb_LogSelect ( data_Log a_log  ) 

Definition at line 33 of file cdb_logselect.cpp.

References dbg_NORM, GetBufferSize(), hton(), log_DBG_m, log_FUNC_m, m_logSelectCmd, op_LOG_SELECT, cdb_LogSelect_t::opcode, cdb_LogSelect_t::paramLen, cdb_LogSelect_t::pc, and data_Log::pc_CURCUMUL.

00034     : m_data(a_log) {
00035 
00036     log_FUNC_m(cdb_LogSelect);
00037 
00038     memset(&m_logSelectCmd, 0, sizeof(m_logSelectCmd));
00039     m_logSelectCmd.opcode    = op_LOG_SELECT;
00040 
00041     // Get parameters for CDB from the data
00042 
00043     UInt16_t paramLen = static_cast<UInt16_t>(GetBufferSize());
00044     m_logSelectCmd.paramLen  = hton(paramLen);
00045 
00046     // 
00047     // WARNING: page control bits must be set to currunt cumulative
00048     // values if the parameter length is != 0!!
00049     // 
00050     if (paramLen > 0) {
00051         m_logSelectCmd.pc = data_Log::pc_CURCUMUL;
00052     };
00053 
00054     log_DBG_m(dbg_NORM, "LOG SELECT: Parameter length: " << paramLen);
00055 }

Here is the call graph for this function:

cdb_LogSelect::~cdb_LogSelect (  )  [virtual]

Definition at line 57 of file cdb_logselect.cpp.

00057                              {
00058 }


Member Function Documentation

const UInt8_t * cdb_LogSelect::GetCmdPointer (  )  const [virtual]

Reimplemented from scsi_CDB.

Definition at line 69 of file cdb_logselect.cpp.

References m_logSelectCmd.

00069                                                   {
00070     return reinterpret_cast<UInt8_t*>(
00071         const_cast<cdb_LogSelect_t*>(&m_logSelectCmd) );
00072 }

UInt32_t cdb_LogSelect::GetCmdSize (  )  const [virtual]

Reimplemented from scsi_CDB.

Definition at line 74 of file cdb_logselect.cpp.

References m_logSelectCmd.

00074                                          {
00075     return sizeof(m_logSelectCmd);
00076 }

Direction_e cdb_LogSelect::GetTransferDirection (  )  const [virtual]

Implements scsi_CDB.

Definition at line 78 of file cdb_logselect.cpp.

References TRANSFER_OUT.

00078                                                       {
00079     return TRANSFER_OUT;
00080 }

UInt8_t * cdb_LogSelect::GetBufferPointer (  )  const [virtual]

Reimplemented from scsi_CDB.

Definition at line 60 of file cdb_logselect.cpp.

References data_Log::GetLogStruct(), and m_data.

00060                                                {
00061     return reinterpret_cast<UInt8_t*>(
00062         const_cast<data_Log_t*>(&(m_data.GetLogStruct())) );
00063 }

Here is the call graph for this function:

UInt32_t cdb_LogSelect::GetBufferSize (  )  const [virtual]

Reimplemented from scsi_CDB.

Definition at line 65 of file cdb_logselect.cpp.

References data_Log::GetSize(), and m_data.

Referenced by cdb_LogSelect().

00065                                             {
00066     return m_data.GetSize();
00067 }

Here is the call graph for this function:

Here is the caller graph for this function:

const data_Log & cdb_LogSelect::GetData (  )  const

Definition at line 82 of file cdb_logselect.cpp.

References m_data.

00082                                              {
00083     return m_data;
00084 }


Member Data Documentation

Reimplemented from scsi_CDB.

Definition at line 513 of file cdb.h.

Definition at line 515 of file cdb.h.

Referenced by cdb_LogSelect(), GetCmdPointer(), and GetCmdSize().

Definition at line 516 of file cdb.h.

Referenced by GetBufferPointer(), GetBufferSize(), and GetData().


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

Generated on Mon Feb 27 19:02:23 2012 for OPENARCHIVE by  doxygen 1.5.6