ctkDicomExampleHost.cpp 687 B

1234567891011121314151617181920212223242526272829
  1. #include "ctkDicomExampleHost.h"
  2. #include <QProcess>
  3. #include <QtDebug>
  4. ctkDicomExampleHost::ctkDicomExampleHost() : ctkDicomAbstractHost(8080)
  5. {
  6. }
  7. int ctkDicomExampleHost::StartApplication(QString AppPath, QString App_URL, int port){
  8. QStringList l;
  9. l.append("--hostURL");
  10. l.append("localhost:"+this->getPort());
  11. l.append("--applicationURL");
  12. l.append(App_URL+":"+QString(port));
  13. if (!QProcess::startDetached (
  14. AppPath,l))
  15. {
  16. qCritical() << "application failed to start!";
  17. }
  18. }
  19. void ctkDicomExampleHost::notifyStateChanged(ctkDicomWG23::State state){
  20. }
  21. void ctkDicomExampleHost::notifyStatus(const ctkDicomWG23::Status& status){
  22. }