Class PortNotOpenException
- Namespace
- Loehnert.Lisrt.Communication
- Assembly
- Loehnert.Lisrt.Communication.dll
A localizable exception for accessing a closed port.
[Serializable]
public class PortNotOpenException : InvalidOperationException, ISerializable, _Exception, ITranslatableException, ITranslatableText
- Inheritance
-
PortNotOpenException
- Implements
- Inherited Members
Constructors
PortNotOpenException(string)
Initializes a new instance of the PortNotOpenException class.
public PortNotOpenException(string portName)
Parameters
portName
stringName for the port.
Properties
Message
Gets the localized exception message.
public override string Message { get; }
Property Value
MessageNumber
Gets the message number.
public int MessageNumber { get; }
Property Value
Remarks
Equal with a ID.
PortName
Gets the name of the port.
public string PortName { get; }
Property Value
Methods
GetObjectData(SerializationInfo, StreamingContext)
Sets the System.Runtime.Serialization.SerializationInfo with information about the exception.
[SecurityPermission(SecurityAction.Demand, SerializationFormatter = true)]
public override void GetObjectData(SerializationInfo info, StreamingContext context)
Parameters
info
SerializationInfoThe System.Runtime.Serialization.SerializationInfo that holds the serialized object data about the exception being thrown.
context
StreamingContextThe System.Runtime.Serialization.StreamingContext that contains contextual information about the source or destination.
Translate(CultureInfo)
Translates the Message.
public string Translate(CultureInfo culture)
Parameters
culture
CultureInfoCulture for the returning message.
Returns
- string
Translated message text.