Neuron®
The Neuron® is the basis for the creation of open and secure federated networks for smart societies.
Loading...
Searching...
No Matches
ServerAdminReportNode.cs
1using System.Threading.Tasks;
2using Waher.Reports;
3using Waher.Things;
4
6{
11 public abstract class ServerAdminReportNode : ReportNode
12 {
20 : base(NodeId, Parent)
21 {
22 }
23
29 public override Task<bool> CanViewAsync(RequestOrigin Caller)
30 {
31 return Task.FromResult(Caller.HasPrivilege("Source." + ReportsDataSource.SourceID + ".Node.View"));
32 }
33 }
34}
Abstract base class for report nodes.
Definition: ReportNode.cs:15
INode Parent
Parent Node, or null if a root node.
Definition: ReportNode.cs:107
string NodeId
ID of node.
Definition: ReportNode.cs:39
Defines the Reports data source. This data source contains a tree structure of reports published by d...
const string SourceID
Source ID for the reports data source.
Abstract base class for server report nodes, requiring admin privileges to be seen and executed.
override Task< bool > CanViewAsync(RequestOrigin Caller)
If the node is visible to the caller.
ServerAdminReportNode(string NodeId, ReportNode Parent)
Abstract base class for server report nodes, requiring admin privileges to be seen and executed.
Tokens available in request.
Definition: RequestOrigin.cs:9
bool HasPrivilege(string Privilege)
If the origin has a given privilege.