Stellarium 0.15.2
List of all members | Classes | Public Member Functions | Protected Member Functions
MainService Class Reference

Implements the main API services, including the status operation which can be repeatedly polled to find the current state of the main program, including time, view, location, StelAction and StelProperty state changes, movement, script status ... More...

#include <MainService.hpp>

+ Inheritance diagram for MainService:
+ Collaboration diagram for MainService:

Public Member Functions

 MainService (const QByteArray &serviceName, QObject *parent=0)
 
virtual void update (double deltaTime) Q_DECL_OVERRIDE
 Used to implement move functionality. More...
 
- Public Member Functions inherited from AbstractAPIService
 AbstractAPIService (const QByteArray &serviceName, QObject *parent=0)
 Abstract constructor. The service name is used by the APIController for request path mapping. More...
 
QByteArray serviceName ()
 Returns the service name, used for request path mapping by the APIController. More...
 
virtual bool supportsThreadedOperation () const
 Return true if the service can safely be run in the HTTP handler thread, instead of having to queue it into the Stellarium main thread. More...
 
Q_INVOKABLE APIServiceResponse get (const QByteArray &operation, const APIParameters &parameters)
 Wrapper around getImpl(), constructs an APIServiceResponse object for the response and passes it on. More...
 
Q_INVOKABLE APIServiceResponse post (const QByteArray &operation, const APIParameters &parameters, const QByteArray &data)
 Wrapper around postImpl(), constructs an APIServiceResponse object for the response and passes it on. More...
 

Protected Member Functions

virtual void getImpl (const QByteArray &operation, const APIParameters &parameters, APIServiceResponse &response) Q_DECL_OVERRIDE
 Implements the GET operations. More...
 
virtual void postImpl (const QByteArray &operation, const APIParameters &parameters, const QByteArray &data, APIServiceResponse &response) Q_DECL_OVERRIDE
 Implements the HTTP POST operations. More...
 
- Protected Member Functions inherited from AbstractAPIService
QString wrapHtml (QString &text, const QString &title) const
 Because the HTML descriptions in Stellarium are often not compatible with "clean" HTML5 which is used for the main interface, this method can be used to explicitely set the doctype to 4.01 transitional for better results, and include the stylesheet iframestyle.css. More...
 

Additional Inherited Members

- Static Protected Attributes inherited from AbstractAPIService
static const Qt::ConnectionType SERVICE_DEFAULT_INVOKETYPE
 This defines the connection type QMetaObject::invokeMethod has to use inside a service: either Qt::DirectConnection for main thread handling, or Qt::BlockingQueuedConnection for HTTP thread handling. More...
 

Detailed Description

Implements the main API services, including the status operation which can be repeatedly polled to find the current state of the main program, including time, view, location, StelAction and StelProperty state changes, movement, script status ...

See also
MainService operations (/api/main/)

Definition at line 47 of file MainService.hpp.

Member Function Documentation

virtual void MainService::getImpl ( const QByteArray &  operation,
const APIParameters parameters,
APIServiceResponse response 
)
protectedvirtual

Implements the GET operations.

See also
GET operations

Reimplemented from AbstractAPIService.

virtual void MainService::postImpl ( const QByteArray &  operation,
const APIParameters parameters,
const QByteArray &  data,
APIServiceResponse response 
)
protectedvirtual

Implements the HTTP POST operations.

See also
POST operations

Reimplemented from AbstractAPIService.

virtual void MainService::update ( double  deltaTime)
virtual

Used to implement move functionality.

Reimplemented from AbstractAPIService.


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