SimCenterCommon
Common functionality used within different SimCenter projects
SimCenterFileInput Class Reference

#include <SimCenterFileInput.h>

Inheritance diagram for SimCenterFileInput:
Collaboration diagram for SimCenterFileInput:

Public Member Functions

 SimCenterFileInput (const QJsonValue &inputObject, QWidget *parent=nullptr)
 
virtual ~SimCenterFileInput ()
 
void chooseInputFile ()
 
bool inputFromJSON (QJsonObject &jsonObject) override
 
bool outputToJSON (QJsonObject &jsonObject) override
 
- Public Member Functions inherited from SimCenterWidget
 SimCenterWidget (QWidget *parent=0)
 
virtual ~SimCenterWidget ()
 

Protected Attributes

QLineEdit * theFileLineEdit
 
QLabel * theFileLabel
 

Additional Inherited Members

- Signals inherited from SimCenterWidget
void sendFatalMessage (QString message)
 sendFatalMessage signal to be emitted when object needs to shut program down More...
 
void sendErrorMessage (QString message)
 sendErrorMessage signal to be emitted when object needs to communicate error with user More...
 
void sendStatusMessage (QString message)
 sendStatusMessage signal to be emitted when object needs to communicate status with user More...
 

Detailed Description

Definition at line 47 of file SimCenterFileInput.h.

Constructor & Destructor Documentation

SimCenterFileInput::SimCenterFileInput ( const QJsonValue &  inputObject,
QWidget *  parent = nullptr 
)

Create new SimCenterFileInput widget

Parameters
[in]inputObjectInput JSON object
[in]parentParent widget. Defaults to null pointer

Definition at line 50 of file SimCenterFileInput.cpp.

virtual SimCenterFileInput::~SimCenterFileInput ( )
inlinevirtual

Default destructor

Definition at line 61 of file SimCenterFileInput.h.

Member Function Documentation

void SimCenterFileInput::chooseInputFile ( )

Set input file based on user selection

Definition at line 71 of file SimCenterFileInput.cpp.

bool SimCenterFileInput::inputFromJSON ( QJsonObject &  jsonObject)
overridevirtual

Instantiate the file input from from input JSON object

Parameters
[in]jsonObjectJSON object containing input information
Returns
Returns true if successful, false otherwise

Reimplemented from SimCenterWidget.

Definition at line 77 of file SimCenterFileInput.cpp.

bool SimCenterFileInput::outputToJSON ( QJsonObject &  jsonObject)
overridevirtual

Write all current class data to JSON required to reconstruct class

Parameters
[in,out]jsonObjectJSON object to write output to
Returns
Returns true if successful, false otherwise

Reimplemented from SimCenterWidget.

Definition at line 86 of file SimCenterFileInput.cpp.

Member Data Documentation

QLabel* SimCenterFileInput::theFileLabel
protected

Definition at line 84 of file SimCenterFileInput.h.

QLineEdit* SimCenterFileInput::theFileLineEdit
protected

Definition at line 83 of file SimCenterFileInput.h.


The documentation for this class was generated from the following files: