Neuron®
The Neuron® is the basis for the creation of open and secure federated networks for smart societies.
Loading...
Searching...
No Matches
Waher.Reports.ReportNode Class Referenceabstract

Abstract base class for report nodes. More...

Inheritance diagram for Waher.Reports.ReportNode:
Waher.Things.INode Waher.Things.IThingReference Waher.Reports.Files.ReportFileNode Waher.Reports.ReportsFolder Waher.Service.IoTBroker.Sources.Reports.ServerAdminReportNode Waher.Reports.Files.ReportFilesFolder Waher.Service.IoTBroker.Sources.Reports.ServerAdminReportsFolder Waher.Service.IoTBroker.Sources.Reports.Events.EventStatisticsNode Waher.Service.IoTBroker.Sources.Reports.Events.SearchEventLogNode Waher.Service.IoTBroker.Sources.Reports.Performance.All Waher.Service.IoTBroker.Sources.Reports.Performance.AllocatedMemory Waher.Service.IoTBroker.Sources.Reports.Performance.Cpu Waher.Service.IoTBroker.Sources.Reports.Performance.FreeHD Waher.Service.IoTBroker.Sources.Reports.Performance.FreeMemory Waher.Service.IoTBroker.Sources.Reports.Performance.LockedObjects Waher.Service.IoTBroker.Sources.Reports.Protocols.HttpProtocol Waher.Service.IoTBroker.Sources.Reports.Protocols.XmppProtocol

Public Member Functions

 ReportNode (string NodeId, ReportNode Parent)
 Abstract base class for report nodes. More...
 
virtual Task< string > GetTypeNameAsync (Language Language)
 Gets the type name of the node. More...
 
virtual Task< bool > CanViewAsync (RequestOrigin Caller)
 If the node is visible to the caller. More...
 
Task< bool > CanEditAsync (RequestOrigin Caller)
 If the node can be edited by the caller. More...
 
Task< bool > CanAddAsync (RequestOrigin Caller)
 If the node can be added to by the caller. More...
 
Task< bool > CanDestroyAsync (RequestOrigin Caller)
 If the node can be destroyed to by the caller. More...
 
virtual Task< IEnumerable< Parameter > > GetDisplayableParametersAsync (Language Language, RequestOrigin Caller)
 Gets displayable parameters. More...
 
Task< IEnumerable< Message > > GetMessagesAsync (RequestOrigin Caller)
 Gets messages logged on the node. More...
 
Task< bool > MoveUpAsync (RequestOrigin Caller)
 Tries to move the node up. More...
 
Task< bool > MoveDownAsync (RequestOrigin Caller)
 Tries to move the node down. More...
 
Task< bool > AcceptsParentAsync (INode Parent)
 If the node accepts a presumptive parent, i.e. can be added to that parent (if that parent accepts the node as a child). More...
 
Task< bool > AcceptsChildAsync (INode Child)
 If the node accepts a presumptive child, i.e. can receive as a child (if that child accepts the node as a parent). More...
 
Task AddAsync (INode Child)
 Adds a new child to the node. More...
 
Task UpdateAsync ()
 Updates the node (in persisted storage). More...
 
Task< bool > RemoveAsync (INode Child)
 Removes a child from the node. More...
 
virtual Task DestroyAsync ()
 Destroys the node. If it is a child to a parent node, it is removed from the parent first. More...
 
abstract Task< ExecuteReport > GetExecuteCommand ()
 Gets the command object to execute a report. If null is returned, the report node is just a group placeholder of sub-reports. More...
 

Properties

string NodeId [get]
 ID of node. More...
 
string SourceId [get]
 Optional ID of source containing node. More...
 
string Partition [get]
 Optional partition in which the Node ID is unique. More...
 
virtual string LocalId [get]
 If provided, an ID for the node, but unique locally between siblings. Can be null, if Local ID equal to Node ID. More...
 
virtual string LogId [get]
 If provided, an ID for the node, as it would appear or be used in system logs. Can be null, if Log ID equal to Node ID. More...
 
bool HasChildren [get]
 If the source has any child sources. More...
 
bool ChildrenOrdered [get]
 If the children of the node have an intrinsic order (true), or if the order is not important (false). More...
 
bool IsReadable [get]
 If the node can be read. More...
 
bool IsControllable [get]
 If the node can be controlled. More...
 
bool HasCommands [get]
 If the node has registered commands or not. More...
 
INode Parent [get]
 Parent Node, or null if a root node. More...
 
DateTime LastChanged [get]
 When the node was last updated. More...
 
NodeState State [get]
 Current overall state of the node. More...
 
Task< IEnumerable< INode > > ChildNodes [get]
 Child nodes. If no child nodes are available, null is returned. More...
 
Task< IEnumerable< ICommand > > Commands [get]
 Available command objects. If no commands are available, null is returned. More...
 

Detailed Description

Abstract base class for report nodes.

Definition at line 14 of file ReportNode.cs.

Constructor & Destructor Documentation

◆ ReportNode()

Waher.Reports.ReportNode.ReportNode ( string  NodeId,
ReportNode  Parent 
)

Abstract base class for report nodes.

Parameters
NodeIdNode ID
ParentParent Node, or null if a root node.

Definition at line 27 of file ReportNode.cs.

Member Function Documentation

◆ AcceptsChildAsync()

Task< bool > Waher.Reports.ReportNode.AcceptsChildAsync ( INode  Child)

If the node accepts a presumptive child, i.e. can receive as a child (if that child accepts the node as a parent).

Parameters
ChildPresumptive child node.
Returns
If the child is acceptable.

Implements Waher.Things.INode.

Definition at line 228 of file ReportNode.cs.

◆ AcceptsParentAsync()

Task< bool > Waher.Reports.ReportNode.AcceptsParentAsync ( INode  Parent)

If the node accepts a presumptive parent, i.e. can be added to that parent (if that parent accepts the node as a child).

Parameters
ParentPresumptive parent node.
Returns
If the parent is acceptable.

Implements Waher.Things.INode.

Definition at line 218 of file ReportNode.cs.

◆ AddAsync()

Task Waher.Reports.ReportNode.AddAsync ( INode  Child)

Adds a new child to the node.

Parameters
ChildNew child to add.

Implements Waher.Things.INode.

Definition at line 237 of file ReportNode.cs.

◆ CanAddAsync()

Task< bool > Waher.Reports.ReportNode.CanAddAsync ( RequestOrigin  Caller)

If the node can be added to by the caller.

Parameters
CallerInformation about caller.
Returns
If the node can be added to by the caller.

Implements Waher.Things.INode.

Definition at line 158 of file ReportNode.cs.

◆ CanDestroyAsync()

Task< bool > Waher.Reports.ReportNode.CanDestroyAsync ( RequestOrigin  Caller)

If the node can be destroyed to by the caller.

Parameters
CallerInformation about caller.
Returns
If the node can be destroyed to by the caller.

Implements Waher.Things.INode.

Definition at line 168 of file ReportNode.cs.

◆ CanEditAsync()

Task< bool > Waher.Reports.ReportNode.CanEditAsync ( RequestOrigin  Caller)

If the node can be edited by the caller.

Parameters
CallerInformation about caller.
Returns
If the node can be edited by the caller.

Implements Waher.Things.INode.

Definition at line 148 of file ReportNode.cs.

◆ CanViewAsync()

virtual Task< bool > Waher.Reports.ReportNode.CanViewAsync ( RequestOrigin  Caller)
virtual

If the node is visible to the caller.

Parameters
CallerInformation about caller.
Returns
If the node is visible to the caller.

Implements Waher.Things.INode.

Reimplemented in Waher.Service.IoTBroker.Sources.Reports.ServerAdminReportNode, Waher.Service.IoTBroker.Sources.Reports.ServerAdminReportsFolder, and Waher.Reports.Files.ReportFileNode.

Definition at line 138 of file ReportNode.cs.

◆ DestroyAsync()

virtual Task Waher.Reports.ReportNode.DestroyAsync ( )
virtual

Destroys the node. If it is a child to a parent node, it is removed from the parent first.

Implements Waher.Things.INode.

Definition at line 286 of file ReportNode.cs.

◆ GetDisplayableParametersAsync()

virtual Task< IEnumerable< Parameter > > Waher.Reports.ReportNode.GetDisplayableParametersAsync ( Language  Language,
RequestOrigin  Caller 
)
virtual

Gets displayable parameters.

Parameters
LanguageLanguage to use.
CallerInformation about caller.
Returns
Set of displayable parameters.

Implements Waher.Things.INode.

Reimplemented in Waher.Service.IoTBroker.Sources.Reports.Protocols.HttpProtocol, and Waher.Service.IoTBroker.Sources.Reports.Protocols.XmppProtocol.

Definition at line 179 of file ReportNode.cs.

◆ GetExecuteCommand()

◆ GetMessagesAsync()

Task< IEnumerable< Message > > Waher.Reports.ReportNode.GetMessagesAsync ( RequestOrigin  Caller)

Gets messages logged on the node.

Returns
Set of messages.

Implements Waher.Things.INode.

Definition at line 188 of file ReportNode.cs.

◆ GetTypeNameAsync()

virtual Task< string > Waher.Reports.ReportNode.GetTypeNameAsync ( Language  Language)
virtual

◆ MoveDownAsync()

Task< bool > Waher.Reports.ReportNode.MoveDownAsync ( RequestOrigin  Caller)

Tries to move the node down.

Parameters
CallerInformation about caller.
Returns
If the node was moved down.

Implements Waher.Things.INode.

Definition at line 208 of file ReportNode.cs.

◆ MoveUpAsync()

Task< bool > Waher.Reports.ReportNode.MoveUpAsync ( RequestOrigin  Caller)

Tries to move the node up.

Parameters
CallerInformation about caller.
Returns
If the node was moved up.

Implements Waher.Things.INode.

Definition at line 198 of file ReportNode.cs.

◆ RemoveAsync()

Task< bool > Waher.Reports.ReportNode.RemoveAsync ( INode  Child)

Removes a child from the node.

Parameters
ChildChild to remove.
Returns
If the Child node was found and removed.

Implements Waher.Things.INode.

Definition at line 269 of file ReportNode.cs.

◆ UpdateAsync()

Task Waher.Reports.ReportNode.UpdateAsync ( )

Updates the node (in persisted storage).

Implements Waher.Things.INode.

Property Documentation

◆ ChildNodes

Task<IEnumerable<INode> > Waher.Reports.ReportNode.ChildNodes
get

Child nodes. If no child nodes are available, null is returned.

Implements Waher.Things.INode.

Definition at line 122 of file ReportNode.cs.

◆ ChildrenOrdered

bool Waher.Reports.ReportNode.ChildrenOrdered
get

If the children of the node have an intrinsic order (true), or if the order is not important (false).

Implements Waher.Things.INode.

Definition at line 87 of file ReportNode.cs.

◆ Commands

Task<IEnumerable<ICommand> > Waher.Reports.ReportNode.Commands
get

Available command objects. If no commands are available, null is returned.

Implements Waher.Things.INode.

Definition at line 294 of file ReportNode.cs.

◆ HasChildren

bool Waher.Reports.ReportNode.HasChildren
get

If the source has any child sources.

Implements Waher.Things.INode.

Definition at line 73 of file ReportNode.cs.

◆ HasCommands

bool Waher.Reports.ReportNode.HasCommands
get

If the node has registered commands or not.

Implements Waher.Things.INode.

Definition at line 102 of file ReportNode.cs.

◆ IsControllable

bool Waher.Reports.ReportNode.IsControllable
get

If the node can be controlled.

Implements Waher.Things.INode.

Definition at line 97 of file ReportNode.cs.

◆ IsReadable

bool Waher.Reports.ReportNode.IsReadable
get

If the node can be read.

Implements Waher.Things.INode.

Definition at line 92 of file ReportNode.cs.

◆ LastChanged

DateTime Waher.Reports.ReportNode.LastChanged
get

When the node was last updated.

Implements Waher.Things.INode.

Definition at line 112 of file ReportNode.cs.

◆ LocalId

virtual string Waher.Reports.ReportNode.LocalId
get

If provided, an ID for the node, but unique locally between siblings. Can be null, if Local ID equal to Node ID.

Implements Waher.Things.INode.

Definition at line 54 of file ReportNode.cs.

◆ LogId

virtual string Waher.Reports.ReportNode.LogId
get

If provided, an ID for the node, as it would appear or be used in system logs. Can be null, if Log ID equal to Node ID.

Implements Waher.Things.INode.

Definition at line 59 of file ReportNode.cs.

◆ NodeId

string Waher.Reports.ReportNode.NodeId
get

ID of node.

Implements Waher.Things.IThingReference.

Definition at line 39 of file ReportNode.cs.

◆ Parent

INode Waher.Reports.ReportNode.Parent
get

Parent Node, or null if a root node.

Implements Waher.Things.INode.

Definition at line 107 of file ReportNode.cs.

◆ Partition

string Waher.Reports.ReportNode.Partition
get

Optional partition in which the Node ID is unique.

Implements Waher.Things.IThingReference.

Definition at line 49 of file ReportNode.cs.

◆ SourceId

string Waher.Reports.ReportNode.SourceId
get

Optional ID of source containing node.

Implements Waher.Things.IThingReference.

Definition at line 44 of file ReportNode.cs.

◆ State

NodeState Waher.Reports.ReportNode.State
get

Current overall state of the node.

Implements Waher.Things.INode.

Definition at line 117 of file ReportNode.cs.


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