diff --git a/SabreTools.CommandLine/CommandSet.cs b/SabreTools.CommandLine/CommandSet.cs
index 687c1f4..b70edb1 100644
--- a/SabreTools.CommandLine/CommandSet.cs
+++ b/SabreTools.CommandLine/CommandSet.cs
@@ -40,6 +40,20 @@ namespace SabreTools.CommandLine
#endregion
+ #region Properties
+
+ ///
+ /// Feature that represents the default functionality
+ /// for a command set
+ ///
+ ///
+ /// It is recommended to use this in applications that
+ /// do not need multiple distinct functional modes
+ ///
+ public Feature? DefaultFeature { get; set; }
+
+ #endregion
+
#region Constructors
///
@@ -762,6 +776,17 @@ namespace SabreTools.CommandLine
output.AddRange(outputs);
}
+ // If there is a default feature
+ if (DefaultFeature != null)
+ {
+ foreach (var input in DefaultFeature.Children)
+ {
+ var outputs = input.Value.Format(pre: 2, midpoint: 30, detailed);
+ if (outputs != null)
+ output.AddRange(outputs);
+ }
+ }
+
// Append the footer, if needed
if (_footer.Count > 0)
output.AddRange(_footer);
@@ -792,6 +817,17 @@ namespace SabreTools.CommandLine
output.AddRange(outputs);
}
+ // If there is a default feature
+ if (DefaultFeature != null)
+ {
+ foreach (var input in DefaultFeature.Children)
+ {
+ var outputs = input.Value.Format(pre: 2, midpoint: 30, detailed);
+ if (outputs != null)
+ output.AddRange(outputs);
+ }
+ }
+
// Append the footer, if needed
if (_footer.Count > 0)
output.AddRange(_footer);