ActiveHost class Null safety

ActiveHost which implements comparable By default sort by hostId ascending

Inheritance

Constructors

ActiveHost({required InternetAddress internetAddress, List<OpenPort> openPort = const [], PingData? pingData, MdnsInfo? mdnsInfoVar})
ActiveHost.buildWithAddress({required String address, List<OpenPort> openPort = const [], PingData? pingData, MdnsInfo? mdnsInfo})
factory

Properties

address String
read-only
deviceName Future<String>
This device name does not following any guideline and is just some name that we can show for the device. Preferably hostName, if not than mDNS name, if not than will get the value of generic. This value can change after the object got created since getting host name of device is running async function.
read / write
hashCode int
The hash code for this object.
read-only, override
hostId String
read / write
hostName Future<String?>
read / write
internetAddress InternetAddress
read / write
mdnsInfo Future<MdnsInfo?>
Mdns information of this device
read / write
openPort List<OpenPort>
List of all the open port of this device
read / write
pingData PingData
read-only
responseTime Duration?
read-only
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited
weirdHostName String
read / write

Methods

compareTo(ActiveHost other) int
Compares this object to another object.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed.
inherited
setDeviceName() Future<String>
Set some kind of device name. Will try couple of names, if all are null will just return generic
setHostInfo() Future<String?>
Try to find the host name of this device, if not exist host name will stay null
setMdnsInfo() Future<MdnsInfo?>
Try to find the mdns name of this device, if not exist mdns name will be null TODO: search mdns name for each device
toString() String
A string representation of this object.
override
toStringFull() Future<String>

Operators

operator ==(dynamic o) bool
The equality operator.
override

Static Methods

getPingData(String host) PingData

Constants

generic → const String
'Generic Device'