Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

OpieObex::BtObex Class Reference

#include </home/clem/local/src/opie/core/obex/btobex.h>

Collaboration diagram for OpieObex::BtObex:

Collaboration graph
[legend]
List of all members.

Signals

void receivedFile (const QString &path)
void error (int)
void currentTry (unsigned int)
void sent (bool)
void done (bool)

Public Member Functions

 BtObex (QObject *parent, const char *name)
 ~BtObex ()
void receive ()
void send (const QString &, const QString &)
void setReceiveEnabled (bool=false)

Private Slots

void slotExited (Opie::Core::OProcess *proc)
void slotStdOut (Opie::Core::OProcess *, char *, int)
void slotError ()

Private Member Functions

void shutDownReceive ()
void sendNow ()
QString parseOut ()
void received ()
void sendEnd ()

Private Attributes

uint m_count
QString m_file
QString m_outp
QString m_bdaddr
Opie::Core::OProcessm_send
Opie::Core::OProcessm_rec
bool m_receive: 1

Constructor & Destructor Documentation

BtObex::BtObex QObject *  parent,
const char *  name
 

BtObex c'tor look

Definition at line 18 of file btobex.cpp.

References error(), m_count, m_rec, m_receive, m_send, sent(), and slotError().

BtObex::~BtObex  ) 
 

d'tor

Definition at line 30 of file btobex.cpp.

References m_rec, and m_send.


Member Function Documentation

void OpieObex::BtObex::currentTry unsigned  int  )  [signal]
 

The current try to receive data

Referenced by sendNow().

void OpieObex::BtObex::done bool   )  [signal]
 

Referenced by receive(), and received().

void OpieObex::BtObex::error int   )  [signal]
 

error signal if the program couldn't be started or the the connection timed out

Referenced by BtObex(), send(), sendEnd(), sendNow(), and shutDownReceive().

QString BtObex::parseOut  )  [private]
 

Definition at line 157 of file btobex.cpp.

References QValueList< T >::begin(), QValueList< T >::end(), list, m_outp, QString::mid(), pos, QString::remove(), QStringList::split(), and QString::stripWhiteSpace().

Referenced by received().

void BtObex::receive  ) 
 

TODO mbhaynie -- Maybe opd would be a better way to receive. Starting listening to Bluetooth after enabled by the applet a signal gets emitted when received a file

Definition at line 34 of file btobex.cpp.

References OProcess::AllOutput, done(), m_outp, m_rec, m_receive, OProcess::NotifyOnExit, QString::null, OProcess, slotExited(), slotStdOut(), and Opie::Core::OProcess::start().

Referenced by received(), and slotError().

void BtObex::received  )  [private]
 

Definition at line 123 of file btobex.cpp.

References done(), Opie::Core::OProcess::exitStatus(), m_rec, Opie::Core::OProcess::normalExit(), parseOut(), receive(), and receivedFile().

Referenced by slotExited().

void OpieObex::BtObex::receivedFile const QString path  )  [signal]
 

a signal

Parameters:
path The path to the received file

Referenced by received().

void BtObex::send const QString ,
const QString
 

Definition at line 55 of file btobex.cpp.

References error(), Opie::Core::OProcess::isRunning(), m_bdaddr, m_count, m_file, m_rec, and sendNow().

Referenced by OpieObex::SendWidget::slotStartBt().

void BtObex::sendEnd  )  [private]
 

Definition at line 137 of file btobex.cpp.

References error(), Opie::Core::OProcess::exitStatus(), m_send, Opie::Core::OProcess::normalExit(), sendNow(), and sent().

Referenced by slotExited().

void BtObex::sendNow  )  [private]
 

Definition at line 73 of file btobex.cpp.

References currentTry(), QFile::encodeName(), error(), m_bdaddr, m_count, m_file, m_send, OProcess, sent(), Opie::Core::OProcess::setWorkingDirectory(), slotExited(), slotStdOut(), and Opie::Core::OProcess::start().

Referenced by send(), and sendEnd().

void OpieObex::BtObex::sent bool   )  [signal]
 

signal sent The file got beamed to the remote location

Referenced by BtObex(), sendEnd(), and sendNow().

void BtObex::setReceiveEnabled bool  = false  ) 
 

Definition at line 181 of file btobex.cpp.

References m_receive, and shutDownReceive().

void BtObex::shutDownReceive  )  [private]
 

Definition at line 188 of file btobex.cpp.

References error(), Opie::Core::OProcess::isRunning(), and m_rec.

Referenced by setReceiveEnabled().

void BtObex::slotError  )  [private, slot]
 

when sent is done slotError is called we will start receive again

Definition at line 177 of file btobex.cpp.

References m_receive, and receive().

Referenced by BtObex().

void BtObex::slotExited Opie::Core::OProcess proc  )  [private, slot]
 

Definition at line 108 of file btobex.cpp.

References m_rec, m_send, received(), and sendEnd().

Referenced by receive(), and sendNow().

void BtObex::slotStdOut Opie::Core::OProcess ,
char *  ,
int 
[private, slot]
 

Definition at line 115 of file btobex.cpp.

References QString::append(), m_outp, and m_rec.

Referenced by receive(), and sendNow().


Member Data Documentation

QString OpieObex::BtObex::m_bdaddr [private]
 

Definition at line 57 of file btobex.h.

Referenced by send(), and sendNow().

uint OpieObex::BtObex::m_count [private]
 

Definition at line 54 of file btobex.h.

Referenced by BtObex(), send(), and sendNow().

QString OpieObex::BtObex::m_file [private]
 

Definition at line 55 of file btobex.h.

Referenced by send(), and sendNow().

QString OpieObex::BtObex::m_outp [private]
 

Definition at line 56 of file btobex.h.

Referenced by parseOut(), receive(), and slotStdOut().

Opie::Core::OProcess* OpieObex::BtObex::m_rec [private]
 

Definition at line 59 of file btobex.h.

Referenced by BtObex(), receive(), received(), send(), shutDownReceive(), slotExited(), slotStdOut(), and ~BtObex().

bool OpieObex::BtObex::m_receive [private]
 

Definition at line 60 of file btobex.h.

Referenced by BtObex(), receive(), setReceiveEnabled(), and slotError().

Opie::Core::OProcess* OpieObex::BtObex::m_send [private]
 

Definition at line 58 of file btobex.h.

Referenced by BtObex(), sendEnd(), sendNow(), slotExited(), and ~BtObex().


The documentation for this class was generated from the following files:
Generated on Sat Nov 5 18:02:23 2005 for OPIE by  doxygen 1.4.2