-
Notifications
You must be signed in to change notification settings - Fork 1
/
mdnsCore.pas
54 lines (42 loc) · 925 Bytes
/
mdnsCore.pas
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
unit mdnsCore;
interface
uses Types, SysUtils;
type
TmdnsPtrRecord = record
Name: String;
NameHost: String;
end;
TmdnsSrvRecord = record
Name: String;
NameTarget: String;
Port: Word;
Weight: Word;
Priority: Word;
end;
TmdnsTxtRecord = record
Name: String;
Strings: TStringDynArray;
end;
TmdnsARecord = record
Name: String;
IpAddress: String;
end;
TMdnsAaaaRecord = record
Name: String;
IpAddress: String;
end;
TmdnsResult = record
PTR: TmdnsPtrRecord;
SRV: TmdnsSrvRecord;
A: TmdnsARecord;
AAAA: TMdnsAaaaRecord;
TXT: TmdnsTxtRecord;
Host: String;
Port: Word;
isError: Boolean;
Errorcode: Integer;
end;
TmdnsResolveEvent = procedure (Sender: TObject; const Result: TmdnsResult) of object;
mdnsException = class(Exception);
implementation
end.