/// <summary> /// Initializes a new instance of the AlphanumericBehavior class by copying it from /// another AlphanumericBehavior object. </summary> /// <param name="behavior"> /// The AlphanumericBehavior object to copied (and then disposed of). It must not be null. </param> /// <exception cref="ArgumentNullException">behavior is null. </exception> /// <remarks> /// After the behavior.TextBox object is copied, Dispose is called on the behavior parameter. </remarks> public AlphanumericBehavior(AlphanumericBehavior behavior) : base(behavior) { m_invalidChars = behavior.m_invalidChars; }
/// <summary> /// Initializes a new instance of the AlphanumericTextBox class by assigning its Behavior field /// to an instance of <see cref="AlphanumericBehavior" /> and passing it string of characters to consider invalid. </summary> /// <param name="invalidChars"> /// The set of characters not allowed, concatenated into a string. </param> public AlphanumericTextBox(string invalidChars) { m_behavior = new AlphanumericBehavior(this, invalidChars); }
/// <summary> /// Initializes a new instance of the AlphanumericTextBox class by explicitly assigning its Behavior field. </summary> /// <param name="behavior"> /// The <see cref="AlphanumericBehavior" /> object to associate the textbox with. </param> public AlphanumericTextBox(AlphanumericBehavior behavior) : base(behavior) { }
/// <summary> /// Initializes a new instance of the AlphanumericTextBox class by assigning its Behavior field /// to an instance of <see cref="AlphanumericBehavior" />. </summary> public AlphanumericTextBox() { m_behavior = new AlphanumericBehavior(this); }