/// <summary> /// Creates a new ArgShortcut using the given policy /// </summary> /// <param name="policy"></param> public ArgShortcut(ArgShortcutPolicy policy) { if (policy == ArgShortcutPolicy.NoShortcut) { this.Shortcut = null; this.policy = policy; } else { throw new InvalidOperationException("ShortcutAssignment '" + policy + "' is not supported in this context."); } }
/// <summary> /// Creates a new ArgShortcut using the given policy /// </summary> /// <param name="policy"></param> public ArgShortcut(ArgShortcutPolicy policy) { if (policy == ArgShortcutPolicy.NoShortcut) { this.Shortcut = null; this.policy = policy; } else { throw new InvalidOperationException("ShortcutAssignment '" + policy + "' is not supported in this context."); } }
/// <summary> /// Creates a new ArgShortcut using the given policy. /// </summary> /// <param name="policy"></param> public ArgShortcut(ArgShortcutPolicy policy) { this.Policy = policy; }
/// <summary> /// Creates a new ArgShortcut attribute with a specified value. /// </summary> /// <param name="shortcut">The value of the new shortcut.</param> public ArgShortcut(string shortcut) { this.Shortcut = shortcut; this.Policy = ArgShortcutPolicy.Default; }
/// <summary> /// Creates a new ArgShortcut using the given policy /// </summary> /// <param name="policy"></param> public ArgShortcut(ArgShortcutPolicy policy) { this.Policy = policy; }
/// <summary> /// Creates a new ArgShortcut attribute with a specified value. /// </summary> /// <param name="shortcut">The value of the new shortcut.</param> public ArgShortcut(string shortcut) { this.Shortcut = shortcut; this.Policy = ArgShortcutPolicy.Default; }