Description
The Address
property of the Connection
class represents the network address associated with the connection. This property is virtual, allowing derived classes to override its behavior if necessary. It is a public instance property, meaning it can be accessed from outside the class and is specific to each instance of the Connection
class.
Usage
Use the Address
property to retrieve the network address of a specific connection. This can be useful for logging, debugging, or displaying connection information to the user.
Example
// Example of accessing the Address property
Connection connection = Connection.Find(someGuid);
string connectionAddress = connection.Address;
// Output the address
// Note: Avoid using Console.WriteLine in Sandbox
Log.Info($"Connection Address: {connectionAddress}");