C# 클래스 Plasma.DataEngine

상속: Qyoto.QObject, IDisposable
파일 보기 프로젝트 열기: 0xd34df00d/Qross

Private Properties

프로퍼티 타입 설명
ForceImmediateUpdateOfAllVisualizations void
Init void
RemoveSource void
ScheduleSourcesUpdated void
ServiceForSource Service
SourceRequestEvent bool
TimerEvent void
UpdateAllSources void
UpdateSourceEvent bool
sources List

공개 메소드들

메소드 설명
ConnectAllSources ( QObject visualization ) : void
ConnectAllSources ( QObject visualization, uint pollingInterval ) : void
ConnectAllSources ( QObject visualization, uint pollingInterval, Plasma intervalAlignment ) : void Connects all currently existing sources to an object for data updates. The object must have a slot with the following signature: SLOT("dataUpdated(string,Plasma.DataEngine.Data)") The data is a QHash of QVariants keyed by string names, allowing one data source to provide sets of related data. This method may be called multiple times for the same visualization without side-effects. This can be useful to change the pollingInterval. Note that this method does not automatically connect sources that may appear later on. Connecting and responding to the sourceAdded sigal is still required to achieve that. name="visualization" the object to connect the data source to name="pollingInterval" the frequency, in milliseconds, with which to check for updates; a value of 0 (the default) means to update only when there is new data spontaneously generated (e.g. by the engine); any other value results in periodic updates from this source. This value is per-visualization and can be handy for items that require constant updates such as scrolling graphs or clocks. If the data has not changed, no update will be sent. name="intervalAlignment" the number of ms to align the interval to
ConnectSource ( string source, QObject visualization ) : void
ConnectSource ( string source, QObject visualization, uint pollingInterval ) : void
ConnectSource ( string source, QObject visualization, uint pollingInterval, Plasma intervalAlignment ) : void Connects a source to an object for data updates. The object must have a slot with the following signature: dataUpdated(stringsourceName, const Plasma.DataEngine.Data &data) The data is a QHash of QVariants keyed by string names, allowing one data source to provide sets of related data. name="source" the name of the data source name="visualization" the object to connect the data source to name="pollingInterval" the frequency, in milliseconds, with which to check for updates; a value of 0 (the default) means to update only when there is new data spontaneously generated (e.g. by the engine); any other value results in periodic updates from this source. This value is per-visualization and can be handy for items that require constant updates such as scrolling graphs or clocks. If the data has not changed, no update will be sent. name="intervalAlignment" the number of ms to align the interval to
ContainerForSource ( string source ) : DataContainer Retrevies a pointer to the DataContainer for a given source. This method should not be used if possible. An exception is for script engines that can not provide a QMetaObject as required by connectSource for the initial call to dataUpdated. Using this method, such engines can provide their own connectSource API. name="source" the name of the source.
DataEngine ( ) : System
DataEngine ( QObject parent ) : System
DataEngine ( QObject parent, Kimono.KService service ) : System Constructor. name="parent" The parent object. name="service" pointer to the service that describes the engine
DataEngine ( QObject parent, List args ) : System
DisconnectSource ( string source, QObject visualization ) : void Disconnects a source to an object that was receiving data updates. name="source" the name of the data source name="visualization" the object to connect the data source to
Dispose ( ) : void
IsEmpty ( ) : bool Returns true if the data engine is empty, which is to say that it has no data sources currently.
MaxSourceCount ( ) : uint Returns the maximum number of sources this DataEngine will have at any given time.
Name ( ) : string Returns the engine name for the DataEngine
Package ( ) : Package Accessor for the associated Package object if any.
PluginName ( ) : string Returns the plugin name for the applet
Query ( string source ) : QVariant>.Dictionary Gets the Data associated with a data source. The data is a QHash of QVariants keyed by string names, allowing one data source to provide sets of related data. name="source" the data source to retrieve the data for

보호된 메소드들

메소드 설명
AddSource ( Plasma source ) : void Adds an already constructed data source. The DataEngine takes ownership of the DataContainer object. The objectName of the source is used for the source name. name="source" the DataContainer to add to the DataEngine
ContainerDict ( ) : Plasma.DataContainer>.Dictionary
CreateProxy ( ) : void
DataEngine ( Type dummy ) : System
MinimumPollingInterval ( ) : int
RemoveAllData ( string source ) : void Removes all the data associated with a data source. name="source" the name of the data source
RemoveAllSources ( ) : void Removes all data sources
RemoveData ( string source, string key ) : void Removes a data entry from a source name="source" the name of the data source name="key" the data entry to remove
SetData ( string source, QVariant>.Dictionary data ) : void Adds a set of data to a data source. If the source doesn't exist then it is created. name="source" the name of the data source name="data" the data to add to the source
SetData ( string source, Qyoto.QVariant value ) : void Sets a value for a data source. If the source doesn't exist then it is created. name="source" the name of the data source name="value" the data to associated with the source
SetData ( string source, string key, Qyoto.QVariant value ) : void Sets a value for a data source. If the source doesn't exist then it is created. name="source" the name of the data source name="key" the key to use for the data name="value" the data to associated with the source
SetMaxSourceCount ( uint limit ) : void Sets an upper limit on the number of data sources to keep in this engine. If the limit is exceeded, then the oldest data source, as defined by last update, is dropped. name="limit" the maximum number of sources to keep active
SetMinimumPollingInterval ( int minimumMs ) : void Sets the minimum amount of time, in milliseconds, that must pass between successive updates of data. This can help prevent too many updates happening due to multiple update requests coming in, which can be useful for expensive (time- or resource-wise) update mechanisms. name="minimumMs" the minimum time lapse, in milliseconds, between updates. A value less than 0 means to never perform automatic updates, a value of 0 means update immediately on every update request, a value >0 will result in a minimum time lapse being enforced.
SetName ( string name ) : void Sets the engine name for the DataEngine
SetPollingInterval ( uint frequency ) : void Sets up an internal update tick for all data sources. On every update, updateSourceEvent will be called for each applicable source. name="frequency" the time, in milliseconds, between updates. A value of 0 will stop internally triggered updates.

비공개 메소드들

메소드 설명
ForceImmediateUpdateOfAllVisualizations ( ) : void
Init ( ) : void
RemoveSource ( string source ) : void
ScheduleSourcesUpdated ( ) : void
ServiceForSource ( string source ) : Service
SourceRequestEvent ( string source ) : bool
TimerEvent ( Qyoto.QTimerEvent arg1 ) : void
UpdateAllSources ( ) : void
UpdateSourceEvent ( string source ) : bool
sources ( ) : List

메소드 상세

AddSource() 보호된 메소드

Adds an already constructed data source. The DataEngine takes ownership of the DataContainer object. The objectName of the source is used for the source name. name="source" the DataContainer to add to the DataEngine
protected AddSource ( Plasma source ) : void
source Plasma
리턴 void

ConnectAllSources() 공개 메소드

public ConnectAllSources ( QObject visualization ) : void
visualization Qyoto.QObject
리턴 void

ConnectAllSources() 공개 메소드

public ConnectAllSources ( QObject visualization, uint pollingInterval ) : void
visualization Qyoto.QObject
pollingInterval uint
리턴 void

ConnectAllSources() 공개 메소드

Connects all currently existing sources to an object for data updates. The object must have a slot with the following signature: SLOT("dataUpdated(string,Plasma.DataEngine.Data)") The data is a QHash of QVariants keyed by string names, allowing one data source to provide sets of related data. This method may be called multiple times for the same visualization without side-effects. This can be useful to change the pollingInterval. Note that this method does not automatically connect sources that may appear later on. Connecting and responding to the sourceAdded sigal is still required to achieve that. name="visualization" the object to connect the data source to name="pollingInterval" the frequency, in milliseconds, with which to check for updates; a value of 0 (the default) means to update only when there is new data spontaneously generated (e.g. by the engine); any other value results in periodic updates from this source. This value is per-visualization and can be handy for items that require constant updates such as scrolling graphs or clocks. If the data has not changed, no update will be sent. name="intervalAlignment" the number of ms to align the interval to
public ConnectAllSources ( QObject visualization, uint pollingInterval, Plasma intervalAlignment ) : void
visualization Qyoto.QObject
pollingInterval uint
intervalAlignment Plasma
리턴 void

ConnectSource() 공개 메소드

public ConnectSource ( string source, QObject visualization ) : void
source string
visualization Qyoto.QObject
리턴 void

ConnectSource() 공개 메소드

public ConnectSource ( string source, QObject visualization, uint pollingInterval ) : void
source string
visualization Qyoto.QObject
pollingInterval uint
리턴 void

ConnectSource() 공개 메소드

Connects a source to an object for data updates. The object must have a slot with the following signature: dataUpdated(stringsourceName, const Plasma.DataEngine.Data &data) The data is a QHash of QVariants keyed by string names, allowing one data source to provide sets of related data. name="source" the name of the data source name="visualization" the object to connect the data source to name="pollingInterval" the frequency, in milliseconds, with which to check for updates; a value of 0 (the default) means to update only when there is new data spontaneously generated (e.g. by the engine); any other value results in periodic updates from this source. This value is per-visualization and can be handy for items that require constant updates such as scrolling graphs or clocks. If the data has not changed, no update will be sent. name="intervalAlignment" the number of ms to align the interval to
public ConnectSource ( string source, QObject visualization, uint pollingInterval, Plasma intervalAlignment ) : void
source string
visualization Qyoto.QObject
pollingInterval uint
intervalAlignment Plasma
리턴 void

ContainerDict() 보호된 메소드

protected ContainerDict ( ) : Plasma.DataContainer>.Dictionary
리턴 Plasma.DataContainer>.Dictionary

ContainerForSource() 공개 메소드

Retrevies a pointer to the DataContainer for a given source. This method should not be used if possible. An exception is for script engines that can not provide a QMetaObject as required by connectSource for the initial call to dataUpdated. Using this method, such engines can provide their own connectSource API. name="source" the name of the source.
public ContainerForSource ( string source ) : DataContainer
source string
리턴 DataContainer

CreateProxy() 보호된 메소드

protected CreateProxy ( ) : void
리턴 void

DataEngine() 공개 메소드

public DataEngine ( ) : System
리턴 System

DataEngine() 공개 메소드

public DataEngine ( QObject parent ) : System
parent Qyoto.QObject
리턴 System

DataEngine() 공개 메소드

Constructor. name="parent" The parent object. name="service" pointer to the service that describes the engine
public DataEngine ( QObject parent, Kimono.KService service ) : System
parent Qyoto.QObject
service Kimono.KService
리턴 System

DataEngine() 공개 메소드

public DataEngine ( QObject parent, List args ) : System
parent Qyoto.QObject
args List
리턴 System

DataEngine() 보호된 메소드

protected DataEngine ( Type dummy ) : System
dummy System.Type
리턴 System

DisconnectSource() 공개 메소드

Disconnects a source to an object that was receiving data updates. name="source" the name of the data source name="visualization" the object to connect the data source to
public DisconnectSource ( string source, QObject visualization ) : void
source string
visualization Qyoto.QObject
리턴 void

Dispose() 공개 메소드

public Dispose ( ) : void
리턴 void

IsEmpty() 공개 메소드

Returns true if the data engine is empty, which is to say that it has no data sources currently.
public IsEmpty ( ) : bool
리턴 bool

MaxSourceCount() 공개 메소드

Returns the maximum number of sources this DataEngine will have at any given time.
public MaxSourceCount ( ) : uint
리턴 uint

MinimumPollingInterval() 보호된 메소드

protected MinimumPollingInterval ( ) : int
리턴 int

Name() 공개 메소드

Returns the engine name for the DataEngine
public Name ( ) : string
리턴 string

Package() 공개 메소드

Accessor for the associated Package object if any.
public Package ( ) : Package
리턴 Package

PluginName() 공개 메소드

Returns the plugin name for the applet
public PluginName ( ) : string
리턴 string

Query() 공개 메소드

Gets the Data associated with a data source. The data is a QHash of QVariants keyed by string names, allowing one data source to provide sets of related data. name="source" the data source to retrieve the data for
public Query ( string source ) : QVariant>.Dictionary
source string
리턴 QVariant>.Dictionary

RemoveAllData() 보호된 메소드

Removes all the data associated with a data source. name="source" the name of the data source
protected RemoveAllData ( string source ) : void
source string
리턴 void

RemoveAllSources() 보호된 메소드

Removes all data sources
protected RemoveAllSources ( ) : void
리턴 void

RemoveData() 보호된 메소드

Removes a data entry from a source name="source" the name of the data source name="key" the data entry to remove
protected RemoveData ( string source, string key ) : void
source string
key string
리턴 void

SetData() 보호된 메소드

Adds a set of data to a data source. If the source doesn't exist then it is created. name="source" the name of the data source name="data" the data to add to the source
protected SetData ( string source, QVariant>.Dictionary data ) : void
source string
data QVariant>.Dictionary
리턴 void

SetData() 보호된 메소드

Sets a value for a data source. If the source doesn't exist then it is created. name="source" the name of the data source name="value" the data to associated with the source
protected SetData ( string source, Qyoto.QVariant value ) : void
source string
value Qyoto.QVariant
리턴 void

SetData() 보호된 메소드

Sets a value for a data source. If the source doesn't exist then it is created. name="source" the name of the data source name="key" the key to use for the data name="value" the data to associated with the source
protected SetData ( string source, string key, Qyoto.QVariant value ) : void
source string
key string
value Qyoto.QVariant
리턴 void

SetMaxSourceCount() 보호된 메소드

Sets an upper limit on the number of data sources to keep in this engine. If the limit is exceeded, then the oldest data source, as defined by last update, is dropped. name="limit" the maximum number of sources to keep active
protected SetMaxSourceCount ( uint limit ) : void
limit uint
리턴 void

SetMinimumPollingInterval() 보호된 메소드

Sets the minimum amount of time, in milliseconds, that must pass between successive updates of data. This can help prevent too many updates happening due to multiple update requests coming in, which can be useful for expensive (time- or resource-wise) update mechanisms. name="minimumMs" the minimum time lapse, in milliseconds, between updates. A value less than 0 means to never perform automatic updates, a value of 0 means update immediately on every update request, a value >0 will result in a minimum time lapse being enforced.
protected SetMinimumPollingInterval ( int minimumMs ) : void
minimumMs int
리턴 void

SetName() 보호된 메소드

Sets the engine name for the DataEngine
protected SetName ( string name ) : void
name string
리턴 void

SetPollingInterval() 보호된 메소드

Sets up an internal update tick for all data sources. On every update, updateSourceEvent will be called for each applicable source. name="frequency" the time, in milliseconds, between updates. A value of 0 will stop internally triggered updates.
protected SetPollingInterval ( uint frequency ) : void
frequency uint
리턴 void