| 108 | } |
| 109 | |
| 110 | const QString COperateSSH::Description() |
| 111 | { |
| 112 | QString szDescription; |
| 113 | if(!Name().isEmpty()) |
| 114 | szDescription = tr("Name: ") + Name() + "\n"; |
| 115 | |
| 116 | if(!GetTypeName().isEmpty()) |
| 117 | szDescription += tr("Type: ") + GetTypeName() + "\n"; |
| 118 | |
| 119 | if(!Protocol().isEmpty()) { |
| 120 | szDescription += tr("Protocol: ") + Protocol(); |
| 121 | #ifdef DEBUG |
| 122 | if(!GetPlugin()->DisplayName().isEmpty()) |
| 123 | szDescription += " - " + GetPlugin()->DisplayName(); |
| 124 | #endif |
| 125 | szDescription += "\n"; |
| 126 | } |
| 127 | |
| 128 | auto &sshNet = m_Parameters.m_SSH.m_Net; |
| 129 | if(!sshNet.GetHost().isEmpty()) |
| 130 | szDescription += tr("Server address: ") + sshNet.GetHost() |
| 131 | + ":" + QString::number(sshNet.GetPort()) + "\n"; |
| 132 | |
| 133 | CSecurityLevel sl(GetSecurityLevel()); |
| 134 | if(!(GetSecurityLevel() & CSecurityLevel::Level::No)) { |
| 135 | szDescription += tr("Security level: "); |
| 136 | if(!sl.GetUnicodeIcon().isEmpty()) |
| 137 | szDescription += sl.GetUnicodeIcon() + " "; |
| 138 | szDescription += sl.GetString() + "\n"; |
| 139 | } |
| 140 | |
| 141 | if(!GetPlugin()->Description().isEmpty()) |
| 142 | szDescription += tr("Description: ") + GetPlugin()->Description(); |
| 143 | |
| 144 | return szDescription; |
| 145 | } |
| 146 |
nothing calls this directly
no test coverage detected