Esempio n. 1
0
 /// <summary>
 /// Encapsulates a <see cref="Device"/> and its children as a <see cref="DeviceOrphan"/>.
 /// </summary>
 /// <param name="value">The device to encapsulate.</param>
 /// <param name="children">The children of the device.</param>
 /// <returns>A <see cref="DeviceOrphan"/> encapsulating the specified <see cref="Device"/> and children.</returns>
 public override PrtgOrphan Orphan(ITreeValue value, IEnumerable <PrtgOrphan> children) =>
 PrtgOrphan.Device((IDevice)value, children);
Esempio n. 2
0
 /// <summary>
 /// Creates a new <see cref="DeviceNode"/> from a device and its children.
 /// </summary>
 /// <param name="device">The device this node represents.</param>
 /// <param name="children">The children of this node.</param>
 /// <returns>A node containing the specified device and a copy of the children that point to this node as their parent.</returns>
 public static DeviceNode Device(Device device, IEnumerable <PrtgNode> children) =>
 PrtgOrphan.Device(device, GetOrphans(children)).ToStandaloneNode <DeviceNode>();