git-svn-id: svn://db.shs.com.ru/libs@389 a8b55f48-bf90-11e4-a774-851b48703e85

This commit is contained in:
2018-05-28 11:32:38 +00:00
parent f2581cd605
commit 46d6928ebe
12 changed files with 85 additions and 115 deletions

View File

@@ -13,6 +13,27 @@ Interface::Interface(CDType::cdT type_) {
//piCoutObj << (void*)this << core;
file_ = core->typeLetter(type_) + PIStringAscii(".dat");
file_size = 0;
switch (type) {
case CDType::cdK:
CONNECTU(core, K_Sended, this, sended);
CONNECTU(core, K_SendFail, this, sendFailed);
CONNECTU(core, K_Received, this, received);
CONNECTU(core, K_ReceiveFail, this, receiveFailed);
break;
case CDType::cdX:
CONNECTU(core, X_Sended, this, sended);
CONNECTU(core, X_SendFail, this, sendFailed);
CONNECTU(core, X_Received, this, received);
CONNECTU(core, X_ReceiveFail, this, receiveFailed);
break;
case CDType::cdC:
CONNECTU(core, C_Sended, this, sended);
CONNECTU(core, C_SendFail, this, sendFailed);
CONNECTU(core, C_Received, this, received);
CONNECTU(core, C_ReceiveFail, this, receiveFailed);
break;
default: break;
}
}
@@ -164,3 +185,13 @@ void Interface::writeFile() {
bool Interface::inProgress() {
return core->inProgress();
}
void Interface::send() {
core->send(type);
}
void Interface::request() {
core->request(type);
}