Rename helper interfaces.
This commit is contained in:
parent
a2ee82e021
commit
cd4d9b1985
|
@ -129,7 +129,7 @@ bool ExternalCommand::start(int timeout)
|
|||
|
||||
bool rval = false;
|
||||
|
||||
QDBusPendingCall pcall = interface->start(cmd, args(), d->m_Input, d->processChannelMode);
|
||||
QDBusPendingCall pcall = interface->RunCommand(cmd, args(), d->m_Input, d->processChannelMode);
|
||||
|
||||
QDBusPendingCallWatcher *watcher = new QDBusPendingCallWatcher(pcall, this);
|
||||
QEventLoop loop;
|
||||
|
@ -168,7 +168,7 @@ bool ExternalCommand::copyBlocks(const CopySource& source, CopyTarget& target)
|
|||
if (!interface)
|
||||
return false;
|
||||
|
||||
QDBusPendingCall pcall = interface->copyblocks(source.path(), source.firstByte(), source.length(),
|
||||
QDBusPendingCall pcall = interface->CopyBlocks(source.path(), source.firstByte(), source.length(),
|
||||
target.path(), target.firstByte(), blockSize);
|
||||
|
||||
QDBusPendingCallWatcher *watcher = new QDBusPendingCallWatcher(pcall, this);
|
||||
|
@ -205,7 +205,7 @@ bool ExternalCommand::writeData(Report& commandReport, const QByteArray& buffer,
|
|||
if (!interface)
|
||||
return false;
|
||||
|
||||
QDBusPendingCall pcall = interface->writeData(buffer, deviceNode, firstByte);
|
||||
QDBusPendingCall pcall = interface->WriteData(buffer, deviceNode, firstByte);
|
||||
return waitForDbusReply(pcall);
|
||||
}
|
||||
|
||||
|
@ -215,7 +215,7 @@ bool ExternalCommand::createFile(const QByteArray& fileContents, const QString&
|
|||
if (!interface)
|
||||
return false;
|
||||
|
||||
QDBusPendingCall pcall = interface->createFile(filePath, fileContents);
|
||||
QDBusPendingCall pcall = interface->CreateFile(filePath, fileContents);
|
||||
return waitForDbusReply(pcall);
|
||||
}
|
||||
|
||||
|
|
|
@ -127,7 +127,7 @@ bool ExternalCommandHelper::writeData(const QString &targetDevice, const QByteAr
|
|||
@param fileContents the data that we write
|
||||
@return true on success
|
||||
*/
|
||||
bool ExternalCommandHelper::createFile(const QString &filePath, const QByteArray& fileContents)
|
||||
bool ExternalCommandHelper::CreateFile(const QString &filePath, const QByteArray& fileContents)
|
||||
{
|
||||
if (!isCallerAuthorized()) {
|
||||
return false;
|
||||
|
@ -153,7 +153,7 @@ bool ExternalCommandHelper::createFile(const QString &filePath, const QByteArray
|
|||
}
|
||||
|
||||
// If targetDevice is empty then return QByteArray with data that was read from disk.
|
||||
QVariantMap ExternalCommandHelper::copyblocks(const QString& sourceDevice, const qint64 sourceFirstByte, const qint64 sourceLength, const QString& targetDevice, const qint64 targetFirstByte, const qint64 blockSize)
|
||||
QVariantMap ExternalCommandHelper::CopyBlocks(const QString& sourceDevice, const qint64 sourceFirstByte, const qint64 sourceLength, const QString& targetDevice, const qint64 targetFirstByte, const qint64 blockSize)
|
||||
{
|
||||
if (!isCallerAuthorized()) {
|
||||
return QVariantMap();
|
||||
|
@ -245,7 +245,7 @@ QVariantMap ExternalCommandHelper::copyblocks(const QString& sourceDevice, const
|
|||
return reply;
|
||||
}
|
||||
|
||||
bool ExternalCommandHelper::writeData(const QByteArray& buffer, const QString& targetDevice, const qint64 targetFirstByte)
|
||||
bool ExternalCommandHelper::WriteData(const QByteArray& buffer, const QString& targetDevice, const qint64 targetFirstByte)
|
||||
{
|
||||
if (!isCallerAuthorized()) {
|
||||
return false;
|
||||
|
@ -257,7 +257,7 @@ bool ExternalCommandHelper::writeData(const QByteArray& buffer, const QString& t
|
|||
return writeData(targetDevice, buffer, targetFirstByte);
|
||||
}
|
||||
|
||||
QVariantMap ExternalCommandHelper::start(const QString& command, const QStringList& arguments, const QByteArray& input, const int processChannelMode)
|
||||
QVariantMap ExternalCommandHelper::RunCommand(const QString& command, const QStringList& arguments, const QByteArray& input, const int processChannelMode)
|
||||
{
|
||||
if (!isCallerAuthorized()) {
|
||||
return QVariantMap();
|
||||
|
|
|
@ -36,10 +36,10 @@ public:
|
|||
bool writeData(const QString& targetDevice, const QByteArray& buffer, const qint64 offset);
|
||||
|
||||
public Q_SLOTS:
|
||||
Q_SCRIPTABLE QVariantMap start(const QString& command, const QStringList& arguments, const QByteArray& input, const int processChannelMode);
|
||||
Q_SCRIPTABLE QVariantMap copyblocks(const QString& sourceDevice, const qint64 sourceFirstByte, const qint64 sourceLength, const QString& targetDevice, const qint64 targetFirstByte, const qint64 blockSize);
|
||||
Q_SCRIPTABLE bool writeData(const QByteArray& buffer, const QString& targetDevice, const qint64 targetFirstByte);
|
||||
Q_SCRIPTABLE bool createFile(const QString& filePath, const QByteArray& fileContents);
|
||||
Q_SCRIPTABLE QVariantMap RunCommand(const QString& command, const QStringList& arguments, const QByteArray& input, const int processChannelMode);
|
||||
Q_SCRIPTABLE QVariantMap CopyBlocks(const QString& sourceDevice, const qint64 sourceFirstByte, const qint64 sourceLength, const QString& targetDevice, const qint64 targetFirstByte, const qint64 blockSize);
|
||||
Q_SCRIPTABLE bool WriteData(const QByteArray& buffer, const QString& targetDevice, const qint64 targetFirstByte);
|
||||
Q_SCRIPTABLE bool CreateFile(const QString& filePath, const QByteArray& fileContents);
|
||||
|
||||
private:
|
||||
|
||||
|
|
Loading…
Reference in New Issue