Removed unused method

Typo fixes
Applied refactoring
This commit is contained in:
Benjamin Höglinger-Stelzer 2018-11-24 17:11:31 +01:00
parent 33e68a0745
commit 664d7c2445
2 changed files with 8 additions and 16 deletions

5
.gitignore vendored
View File

@ -28,5 +28,6 @@ obj/
_ReSharper*/ _ReSharper*/
[Tt]est[Rr]esult* [Tt]est[Rr]esult*
*.testsettings *.testsettings
PInvokeSerialPort.nupkg *.nupkg
/.vs/PInvokeSerialPort/v15/Server/sqlite3 /.vs
/packages

View File

@ -144,7 +144,7 @@ namespace PInvokeSerialPort
public ASCII XonChar = ASCII.DC1; public ASCII XonChar = ASCII.DC1;
/// <summary> /// <summary>
/// Class contructor /// Class constructor
/// </summary> /// </summary>
public SerialPort(string portName) public SerialPort(string portName)
{ {
@ -152,7 +152,7 @@ namespace PInvokeSerialPort
} }
/// <summary> /// <summary>
/// Class contructor /// Class constructor
/// </summary> /// </summary>
public SerialPort(string portName, int baudRate) public SerialPort(string portName, int baudRate)
{ {
@ -316,6 +316,7 @@ namespace PInvokeSerialPort
} }
} }
/// <inheritdoc />
/// <summary> /// <summary>
/// For IDisposable /// For IDisposable
/// </summary> /// </summary>
@ -554,15 +555,6 @@ namespace PInvokeSerialPort
if (!Win32Com.TransmitCommChar(_hPort, tosend)) ThrowException("Transmission failure"); if (!Win32Com.TransmitCommChar(_hPort, tosend)) ThrowException("Transmission failure");
} }
/// <summary>
/// Delay processing.
/// </summary>
/// <param name="milliseconds">Milliseconds to delay by</param>
protected void Sleep(int milliseconds)
{
Thread.Sleep(milliseconds);
}
/// <summary> /// <summary>
/// Gets the status of the modem control input signals. /// Gets the status of the modem control input signals.
/// </summary> /// </summary>
@ -619,8 +611,7 @@ namespace PInvokeSerialPort
/// <param name="ch">The byte that was received</param> /// <param name="ch">The byte that was received</param>
protected void OnRxChar(byte ch) protected void OnRxChar(byte ch)
{ {
if (DataReceived != null) DataReceived?.Invoke(ch);
DataReceived(ch);
} }
/// <summary> /// <summary>
@ -639,7 +630,7 @@ namespace PInvokeSerialPort
} }
/// <summary> /// <summary>
/// Override this to take action when a ring condition is signalled by an attached modem. /// Override this to take action when a ring condition is signaled by an attached modem.
/// </summary> /// </summary>
protected virtual void OnRing() protected virtual void OnRing()
{ {