react-native-zeroconf 0.17.4 → 1.0.0-rc.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (115) hide show
  1. package/NOTICE +2 -6
  2. package/Package.swift +19 -3
  3. package/README.md +1 -3
  4. package/android/CMakeLists.txt +64 -0
  5. package/android/build.gradle +1 -17
  6. package/android/generated/java/com/balthazargronon/RCTZeroconf/NativeZeroconfSpec.java +96 -0
  7. package/android/generated/jni/CMakeLists.txt +28 -0
  8. package/android/generated/jni/RNZeroconfSpec-generated.cpp +77 -0
  9. package/android/generated/jni/RNZeroconfSpec.h +31 -0
  10. package/android/generated/jni/react/renderer/components/RNZeroconfSpec/RNZeroconfSpecJSI.h +798 -0
  11. package/android/src/main/java/com/balthazargronon/RCTZeroconf/{ZeroconfModule.java → NsdHost.java} +97 -140
  12. package/android/src/main/java/com/balthazargronon/RCTZeroconf/NsdPayload.java +87 -0
  13. package/android/src/main/java/com/balthazargronon/RCTZeroconf/NsdPromise.java +40 -0
  14. package/android/src/main/java/com/balthazargronon/RCTZeroconf/Zeroconf.java +4 -6
  15. package/android/src/main/java/com/balthazargronon/RCTZeroconf/ZeroconfNativeSupport.java +60 -0
  16. package/android/src/main/java/com/balthazargronon/RCTZeroconf/ZeroconfOptions.java +15 -26
  17. package/android/src/main/java/com/balthazargronon/RCTZeroconf/ZeroconfReactPackage.java +5 -15
  18. package/android/src/main/java/com/balthazargronon/RCTZeroconf/nsd/NsdServiceImpl.java +90 -96
  19. package/android/src/main/jni/mdnsresponder/mDNSShared/dnssd_clientshim.c +31 -6
  20. package/cpp/Backend.cpp +16 -0
  21. package/cpp/Backend.h +116 -0
  22. package/cpp/ZeroconfModule.cpp +280 -0
  23. package/cpp/ZeroconfModule.h +144 -0
  24. package/cpp/android/NsdBackend.cpp +462 -0
  25. package/cpp/android/NsdBackend.h +61 -0
  26. package/cpp/android/ZeroconfAndroidModule.cpp +49 -0
  27. package/cpp/android/ZeroconfAndroidModule.h +15 -0
  28. package/cpp/apple/DispatchExecutor.cpp +66 -0
  29. package/cpp/apple/DispatchExecutor.h +37 -0
  30. package/cpp/apple/LocalNetworkAccess.h +19 -0
  31. package/cpp/apple/LocalNetworkAccess.mm +87 -0
  32. package/cpp/dnssd/DnssdBackend.cpp +976 -0
  33. package/cpp/dnssd/DnssdBackend.h +114 -0
  34. package/cpp/dnssd/Executor.h +28 -0
  35. package/cpp/embedded/EmbeddedExecutor.cpp +124 -0
  36. package/cpp/embedded/EmbeddedExecutor.h +57 -0
  37. package/ios/ZeroconfOnLoad.mm +34 -0
  38. package/ios/generated/ReactCodegen/RNZeroconfSpec/RNZeroconfSpec-generated.mm +140 -0
  39. package/ios/generated/ReactCodegen/RNZeroconfSpec/RNZeroconfSpec.h +189 -0
  40. package/ios/generated/ReactCodegen/RNZeroconfSpecJSI.h +798 -0
  41. package/lib/module/NativeZeroconf.js +15 -0
  42. package/lib/module/NativeZeroconf.js.map +1 -0
  43. package/lib/module/bridge.js +124 -0
  44. package/lib/module/bridge.js.map +1 -0
  45. package/{dist → lib/module}/index.js +149 -149
  46. package/lib/module/index.js.map +1 -0
  47. package/lib/module/package.json +1 -0
  48. package/lib/module/types.js +24 -0
  49. package/lib/module/types.js.map +1 -0
  50. package/lib/typescript/package.json +1 -0
  51. package/lib/typescript/src/NativeZeroconf.d.ts +75 -0
  52. package/lib/typescript/src/NativeZeroconf.d.ts.map +1 -0
  53. package/lib/typescript/src/bridge.d.ts +22 -0
  54. package/lib/typescript/src/bridge.d.ts.map +1 -0
  55. package/lib/typescript/src/index.d.ts +111 -0
  56. package/lib/typescript/src/index.d.ts.map +1 -0
  57. package/lib/typescript/src/types.d.ts +175 -0
  58. package/lib/typescript/src/types.d.ts.map +1 -0
  59. package/package.json +64 -29
  60. package/react-native-zeroconf.podspec +2 -1
  61. package/react-native.config.js +17 -0
  62. package/src/NativeZeroconf.ts +120 -0
  63. package/src/bridge.ts +153 -0
  64. package/src/index.ts +607 -0
  65. package/{index.d.ts → src/types.ts} +5 -99
  66. package/windows/RNZeroconf/RNZeroconf.vcxproj +17 -2
  67. package/windows/RNZeroconf/RNZeroconf.vcxproj.filters +0 -6
  68. package/windows/RNZeroconf/ReactPackageProvider.cpp +23 -20
  69. package/windows/RNZeroconf/WindowsBackend.cpp +156 -0
  70. package/windows/RNZeroconf/WindowsBackend.h +13 -0
  71. package/windows/RNZeroconf/ZeroconfCore.cpp +2 -2
  72. package/windows/RNZeroconf/ZeroconfCore.h +2 -2
  73. package/windows/RNZeroconf/ZeroconfWindowsModule.cpp +22 -0
  74. package/windows/RNZeroconf/ZeroconfWindowsModule.h +14 -0
  75. package/android/src/main/java/com/balthazargronon/RCTZeroconf/ZeroConfImplFactory.java +0 -56
  76. package/android/src/main/java/com/balthazargronon/RCTZeroconf/dnssd/DnssdImpl.java +0 -654
  77. package/android/src/main/java/com/github/druk/dnssd/BaseListener.java +0 -33
  78. package/android/src/main/java/com/github/druk/dnssd/BrowseListener.java +0 -67
  79. package/android/src/main/java/com/github/druk/dnssd/DNSRecord.java +0 -47
  80. package/android/src/main/java/com/github/druk/dnssd/DNSSD.java +0 -681
  81. package/android/src/main/java/com/github/druk/dnssd/DNSSDEmbedded.java +0 -198
  82. package/android/src/main/java/com/github/druk/dnssd/DNSSDException.java +0 -66
  83. package/android/src/main/java/com/github/druk/dnssd/DNSSDRecordRegistrar.java +0 -55
  84. package/android/src/main/java/com/github/druk/dnssd/DNSSDRegistration.java +0 -54
  85. package/android/src/main/java/com/github/druk/dnssd/DNSSDService.java +0 -35
  86. package/android/src/main/java/com/github/druk/dnssd/DomainListener.java +0 -57
  87. package/android/src/main/java/com/github/druk/dnssd/InternalBrowseListener.java +0 -76
  88. package/android/src/main/java/com/github/druk/dnssd/InternalDNSSD.java +0 -870
  89. package/android/src/main/java/com/github/druk/dnssd/InternalDNSSDRecordRegistrar.java +0 -30
  90. package/android/src/main/java/com/github/druk/dnssd/InternalDNSSDRegistration.java +0 -34
  91. package/android/src/main/java/com/github/druk/dnssd/InternalDNSSDService.java +0 -29
  92. package/android/src/main/java/com/github/druk/dnssd/InternalDomainListener.java +0 -62
  93. package/android/src/main/java/com/github/druk/dnssd/InternalQueryListener.java +0 -61
  94. package/android/src/main/java/com/github/druk/dnssd/InternalRegisterListener.java +0 -51
  95. package/android/src/main/java/com/github/druk/dnssd/InternalResolveListener.java +0 -58
  96. package/android/src/main/java/com/github/druk/dnssd/NSClass.java +0 -16
  97. package/android/src/main/java/com/github/druk/dnssd/NSType.java +0 -58
  98. package/android/src/main/java/com/github/druk/dnssd/QueryListener.java +0 -54
  99. package/android/src/main/java/com/github/druk/dnssd/RegisterListener.java +0 -46
  100. package/android/src/main/java/com/github/druk/dnssd/RegisterRecordListener.java +0 -35
  101. package/android/src/main/java/com/github/druk/dnssd/ResolveListener.java +0 -55
  102. package/android/src/main/java/com/github/druk/dnssd/TXTRecord.java +0 -293
  103. package/android/src/main/jni/Android.mk +0 -73
  104. package/android/src/main/jni/Application.mk +0 -3
  105. package/android/src/main/jni/DNSSD.java.h +0 -290
  106. package/android/src/main/jni/JNISupport.c +0 -1221
  107. package/ios/RNZeroconf/RNNetServiceSerializer.h +0 -31
  108. package/ios/RNZeroconf/RNNetServiceSerializer.m +0 -84
  109. package/ios/RNZeroconf/RNZeroconf.h +0 -17
  110. package/ios/RNZeroconf/RNZeroconf.m +0 -1025
  111. package/ios/RNZeroconf.xcodeproj/project.pbxproj +0 -261
  112. package/ios/RNZeroconf.xcodeproj/project.xcworkspace/contents.xcworkspacedata +0 -7
  113. package/src/index.js +0 -563
  114. package/windows/RNZeroconf/RNZeroconf.cpp +0 -228
  115. package/windows/RNZeroconf/RNZeroconf.h +0 -70
@@ -1,293 +0,0 @@
1
- /* -*- Mode: Java; tab-width: 4 -*-
2
- *
3
- * Copyright (c) 2004 Apple Computer, Inc. All rights reserved.
4
- *
5
- * Licensed under the Apache License, Version 2.0 (the "License");
6
- * you may not use this file except in compliance with the License.
7
- * You may obtain a copy of the License at
8
- *
9
- * http://www.apache.org/licenses/LICENSE-2.0
10
- *
11
- * Unless required by applicable law or agreed to in writing, software
12
- * distributed under the License is distributed on an "AS IS" BASIS,
13
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
- * See the License for the specific language governing permissions and
15
- * limitations under the License.
16
-
17
- To do:
18
- - implement remove()
19
- - fix set() to replace existing values
20
- */
21
-
22
-
23
- package com.github.druk.dnssd;
24
-
25
- // I don't want to change Apple source code
26
- //CHECKSTYLE:OFF
27
-
28
- /**
29
- Object used to construct and parse DNS-SD format TXT records.
30
- For more info see <a href="http://files.dns-sd.org/draft-cheshire-dnsext-dns-sd.txt">DNS-Based Service Discovery</a>, section 6.
31
- */
32
-
33
- public class TXTRecord
34
- {
35
- /*
36
- DNS-SD specifies that a TXT record corresponding to an SRV record consist of
37
- a packed array of bytes, each preceded by a length byte. Each string
38
- is an attribute-value pair.
39
-
40
- The TXTRecord object stores the entire TXT data as a single byte array, traversing it
41
- as need be to implement its various methods.
42
- */
43
-
44
- static final protected byte kAttrSep = '=';
45
-
46
- protected byte[] fBytes;
47
-
48
- /** Constructs a new, empty TXT record. */
49
- public TXTRecord()
50
- { fBytes = new byte[0]; }
51
-
52
- /** Constructs a new TXT record from a byte array in the standard format. */
53
- public TXTRecord( byte[] initBytes)
54
- { fBytes = initBytes.clone(); }
55
-
56
- /** Set a key/value pair in the TXT record. Setting an existing key will replace its value.<P>
57
- @param key
58
- The key name. Must be ASCII, with no '=' characters.
59
- <P>
60
- @param value
61
- Value to be encoded into bytes using the default platform character set.
62
- */
63
- public void set( String key, String value)
64
- {
65
- byte[] valBytes = (value != null) ? value.getBytes() : null;
66
- this.set( key, valBytes);
67
- }
68
-
69
- /** Set a key/value pair in the TXT record. Setting an existing key will replace its value.<P>
70
- @param key
71
- The key name. Must be ASCII, with no '=' characters.
72
- <P>
73
- @param value
74
- Binary representation of the value.
75
- */
76
- public void set( String key, byte[] value)
77
- {
78
- byte[] keyBytes;
79
- int valLen = (value != null) ? value.length : 0;
80
-
81
- try {
82
- keyBytes = key.getBytes( "US-ASCII");
83
- }
84
- catch ( java.io.UnsupportedEncodingException uee) {
85
- throw new IllegalArgumentException();
86
- }
87
-
88
- for ( int i=0; i < keyBytes.length; i++)
89
- if ( keyBytes[i] == '=')
90
- throw new IllegalArgumentException();
91
-
92
- if ( keyBytes.length + valLen >= 255)
93
- throw new ArrayIndexOutOfBoundsException();
94
-
95
- int prevLoc = this.remove( key);
96
- if ( prevLoc == -1)
97
- prevLoc = this.size();
98
-
99
- this.insert( keyBytes, value, prevLoc);
100
- }
101
-
102
- protected void insert( byte[] keyBytes, byte[] value, int index)
103
- // Insert a key-value pair at index
104
- {
105
- byte[] oldBytes = fBytes;
106
- int valLen = (value != null) ? value.length : 0;
107
- int insertion = 0;
108
- int newLen, avLen;
109
-
110
- // locate the insertion point
111
- for ( int i=0; i < index && insertion < fBytes.length; i++)
112
- insertion += (0xFF & (fBytes[ insertion] + 1));
113
-
114
- avLen = keyBytes.length + valLen + (value != null ? 1 : 0);
115
- newLen = avLen + oldBytes.length + 1;
116
-
117
- fBytes = new byte[ newLen];
118
- System.arraycopy( oldBytes, 0, fBytes, 0, insertion);
119
- int secondHalfLen = oldBytes.length - insertion;
120
- System.arraycopy( oldBytes, insertion, fBytes, newLen - secondHalfLen, secondHalfLen);
121
- fBytes[ insertion] = ( byte) avLen;
122
- System.arraycopy( keyBytes, 0, fBytes, insertion + 1, keyBytes.length);
123
- if ( value != null)
124
- {
125
- fBytes[ insertion + 1 + keyBytes.length] = kAttrSep;
126
- System.arraycopy( value, 0, fBytes, insertion + keyBytes.length + 2, valLen);
127
- }
128
- }
129
-
130
- /** Remove a key/value pair from the TXT record. Returns index it was at, or -1 if not found. */
131
- public int remove( String key)
132
- {
133
- int avStart = 0;
134
-
135
- for ( int i=0; avStart < fBytes.length; i++)
136
- {
137
- int avLen = fBytes[ avStart];
138
- if ( key.length() <= avLen &&
139
- ( key.length() == avLen || fBytes[ avStart + key.length() + 1] == kAttrSep))
140
- {
141
- String s = new String( fBytes, avStart + 1, key.length());
142
- if ( 0 == key.compareToIgnoreCase( s))
143
- {
144
- byte[] oldBytes = fBytes;
145
- fBytes = new byte[ oldBytes.length - avLen - 1];
146
- System.arraycopy( oldBytes, 0, fBytes, 0, avStart);
147
- System.arraycopy( oldBytes, avStart + avLen + 1, fBytes, avStart, oldBytes.length - avStart - avLen - 1);
148
- return i;
149
- }
150
- }
151
- avStart += (0xFF & (avLen + 1));
152
- }
153
- return -1;
154
- }
155
-
156
- /** Return the number of keys in the TXT record. */
157
- public int size()
158
- {
159
- int i, avStart;
160
-
161
- for ( i=0, avStart=0; avStart < fBytes.length; i++)
162
- avStart += (0xFF & (fBytes[ avStart] + 1));
163
- return i;
164
- }
165
-
166
- /** Return true if key is present in the TXT record, false if not. */
167
- public boolean contains( String key)
168
- {
169
- String s = null;
170
-
171
- for ( int i=0; null != ( s = this.getKey( i)); i++)
172
- if ( 0 == key.compareToIgnoreCase( s))
173
- return true;
174
- return false;
175
- }
176
-
177
- /** Return a key in the TXT record by zero-based index. Returns null if index exceeds the total number of keys. */
178
- public String getKey( int index)
179
- {
180
- int avStart = 0;
181
-
182
- for ( int i=0; i < index && avStart < fBytes.length; i++)
183
- avStart += fBytes[ avStart] + 1;
184
-
185
- if ( avStart < fBytes.length)
186
- {
187
- int avLen = fBytes[ avStart];
188
- int aLen = 0;
189
-
190
- for ( aLen=0; aLen < avLen; aLen++)
191
- if ( fBytes[ avStart + aLen + 1] == kAttrSep)
192
- break;
193
- return new String( fBytes, avStart + 1, aLen);
194
- }
195
- return null;
196
- }
197
-
198
- /**
199
- Look up a key in the TXT record by zero-based index and return its value. <P>
200
- Returns null if index exceeds the total number of keys.
201
- Returns null if the key is present with no value.
202
- */
203
- public byte[] getValue( int index)
204
- {
205
- int avStart = 0;
206
- byte[] value = null;
207
-
208
- for ( int i=0; i < index && avStart < fBytes.length; i++)
209
- avStart += fBytes[ avStart] + 1;
210
-
211
- if ( avStart < fBytes.length)
212
- {
213
- int avLen = fBytes[ avStart];
214
- int aLen = 0;
215
-
216
- for ( aLen=0; aLen < avLen; aLen++)
217
- {
218
- if ( fBytes[ avStart + aLen + 1] == kAttrSep)
219
- {
220
- value = new byte[ avLen - aLen - 1];
221
- System.arraycopy( fBytes, avStart + aLen + 2, value, 0, avLen - aLen - 1);
222
- break;
223
- }
224
- }
225
- }
226
- return value;
227
- }
228
-
229
- /** Converts the result of getValue() to a string in the platform default character set. */
230
- public String getValueAsString( int index)
231
- {
232
- byte[] value = this.getValue( index);
233
- return value != null ? new String( value) : null;
234
- }
235
-
236
- /** Get the value associated with a key. Will be null if the key is not defined.
237
- Array will have length 0 if the key is defined with an = but no value.<P>
238
-
239
- @param forKey
240
- The left-hand side of the key-value pair.
241
- <P>
242
- @return The binary representation of the value.
243
- */
244
- public byte[] getValue( String forKey)
245
- {
246
- String s = null;
247
- int i;
248
-
249
- for ( i=0; null != ( s = this.getKey( i)); i++)
250
- if ( 0 == forKey.compareToIgnoreCase( s))
251
- return this.getValue( i);
252
- return null;
253
- }
254
-
255
- /** Converts the result of getValue() to a string in the platform default character set.<P>
256
-
257
- @param forKey
258
- The left-hand side of the key-value pair.
259
- <P>
260
- @return The value represented in the default platform character set.
261
- */
262
- public String getValueAsString( String forKey)
263
- {
264
- byte[] val = this.getValue( forKey);
265
- return val != null ? new String( val) : null;
266
- }
267
-
268
- /** Return the contents of the TXT record as raw bytes. */
269
- public byte[] getRawBytes() { return (byte[]) fBytes.clone(); }
270
-
271
- /** Return a string representation of the object. */
272
- public String toString()
273
- {
274
- String a, result = null;
275
-
276
- for ( int i=0; null != ( a = this.getKey( i)); i++)
277
- {
278
- String av = String.valueOf( i) + "={" + a;
279
- String val = this.getValueAsString( i);
280
- if ( val != null)
281
- av += "=" + val + "}";
282
- else
283
- av += "}";
284
- if ( result == null)
285
- result = av;
286
- else
287
- result = result + ", " + av;
288
- }
289
- return result != null ? result : "";
290
- }
291
- }
292
-
293
- //CHECKSTYLE:ON
@@ -1,73 +0,0 @@
1
- LOCAL_PATH := $(call my-dir)
2
-
3
- commonFlags := \
4
- -O2 -g \
5
- -fno-strict-aliasing \
6
- -fwrapv \
7
- -D_GNU_SOURCE \
8
- -DHAVE_IPV6 \
9
- -DHAVE_LINUX \
10
- -DNOT_HAVE_SA_LEN \
11
- -DPLATFORM_NO_RLIMIT \
12
- -DTARGET_OS_LINUX \
13
- -DUSES_NETLINK \
14
- -DMDNS_DEBUGMSGS=0 \
15
- -DMDNS_UDS_SERVERPATH=\"/dev/socket/mdnsd\" \
16
- -DMDNS_USERNAME=\"mdnsr\" \
17
- -W \
18
- -Wall \
19
- -Wextra \
20
- -Wno-array-bounds \
21
- -Wno-pointer-sign \
22
- -Wno-unused \
23
- -Wno-unused-parameter \
24
- -Werror=implicit-function-declaration \
25
-
26
- ### EMBEDDED LIB ###
27
- include $(CLEAR_VARS)
28
-
29
- LOCAL_SDK_VERSION := 8
30
- LOCAL_MODULE := jdns_sd_embedded
31
- LOCAL_SRC_FILES := mdnsresponder/mDNSCore/mDNS.c \
32
- mdnsresponder/mDNSCore/DNSDigest.c \
33
- mdnsresponder/mDNSCore/uDNS.c \
34
- mdnsresponder/mDNSPosix/mDNSPosix.c \
35
- mdnsresponder/mDNSPosix/mDNSUNP.c \
36
- mdnsresponder/mDNSShared/mDNSDebug.c \
37
- mdnsresponder/mDNSShared/dnssd_clientlib.c \
38
- mdnsresponder/mDNSShared/dnssd_clientshim.c \
39
- mdnsresponder/mDNSShared/dnssd_ipc.c \
40
- mdnsresponder/mDNSShared/GenLinkedList.c \
41
- mdnsresponder/mDNSShared/PlatformCommon.c \
42
- mdnsresponder/mDNSCore/DNSCommon.c \
43
- mdnsresponder/mDNSPosix/PosixDaemon.c \
44
- mdnsresponder/mDNSShared/uds_daemon.c \
45
- JNISupport.c
46
-
47
- LOCAL_C_INCLUDES := $(LOCAL_PATH)/mdnsresponder/mDNSPosix \
48
- $(LOCAL_PATH)/mdnsresponder/mDNSCore \
49
- $(LOCAL_PATH)/mdnsresponder/mDNSShared \
50
- $(LOCAL_PATH)
51
-
52
- LOCAL_CFLAGS += -Os -fvisibility=hidden
53
- LOCAL_CFLAGS += $(commonFlags) \
54
- -UMDNS_DEBUGMSGS \
55
- -DMDNS_DEBUGMSGS=0 \
56
- -DSO_REUSEADDR \
57
- -DUNICAST_DISABLED \
58
- -DMDNS_VERSIONSTR_NODTS=1 \
59
- -DAUTO_CALLBACKS=1 \
60
- -DEMBEDDED
61
-
62
- LOCAL_EXPORT_C_INCLUDE_DIRS := external/mdnsresponder/mDNSShared
63
-
64
- ifeq ($(TARGET_BUILD_TYPE),debug)
65
- LOCAL_CFLAGS += -O0 -UNDEBUG -fno-omit-frame-pointer
66
- endif
67
-
68
- LOCAL_LDLIBS := -llog
69
- LOCAL_LDFLAGS += "-Wl,-z,max-page-size=16384"
70
- include $(BUILD_SHARED_LIBRARY)
71
-
72
- # NOTE: Built with 16KB page alignment for Android 15+ compatibility
73
- # See: https://developer.android.com/guide/practices/page-sizes
@@ -1,3 +0,0 @@
1
- APP_ABI := armeabi-v7a arm64-v8a x86 x86_64
2
- APP_PLATFORM := android-21
3
- APP_STL := none
@@ -1,290 +0,0 @@
1
- /* DO NOT EDIT THIS FILE - it is machine generated */
2
- #include <jni.h>
3
- /* Header for class com_apple_dnssd_AppleDNSSD */
4
-
5
- #ifndef _Included_com_apple_dnssd_AppleDNSSD
6
- #define _Included_com_apple_dnssd_AppleDNSSD
7
- #ifdef __cplusplus
8
- extern "C" {
9
- #endif
10
- #undef com_apple_dnssd_AppleDNSSD_MORE_COMING
11
- #define com_apple_dnssd_AppleDNSSD_MORE_COMING 1L
12
- #undef com_apple_dnssd_AppleDNSSD_DEFAULT
13
- #define com_apple_dnssd_AppleDNSSD_DEFAULT 4L
14
- #undef com_apple_dnssd_AppleDNSSD_NO_AUTO_RENAME
15
- #define com_apple_dnssd_AppleDNSSD_NO_AUTO_RENAME 8L
16
- #undef com_apple_dnssd_AppleDNSSD_SHARED
17
- #define com_apple_dnssd_AppleDNSSD_SHARED 16L
18
- #undef com_apple_dnssd_AppleDNSSD_UNIQUE
19
- #define com_apple_dnssd_AppleDNSSD_UNIQUE 32L
20
- #undef com_apple_dnssd_AppleDNSSD_BROWSE_DOMAINS
21
- #define com_apple_dnssd_AppleDNSSD_BROWSE_DOMAINS 64L
22
- #undef com_apple_dnssd_AppleDNSSD_REGISTRATION_DOMAINS
23
- #define com_apple_dnssd_AppleDNSSD_REGISTRATION_DOMAINS 128L
24
- #undef com_apple_dnssd_AppleDNSSD_MAX_DOMAIN_NAME
25
- #define com_apple_dnssd_AppleDNSSD_MAX_DOMAIN_NAME 1009L
26
- #undef com_apple_dnssd_AppleDNSSD_ALL_INTERFACES
27
- #define com_apple_dnssd_AppleDNSSD_ALL_INTERFACES 0L
28
- #undef com_apple_dnssd_AppleDNSSD_LOCALHOST_ONLY
29
- #define com_apple_dnssd_AppleDNSSD_LOCALHOST_ONLY -1L
30
- /*
31
- * Class: com_apple_dnssd_AppleDNSSD
32
- * Method: ConstructName
33
- * Signature: (Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;[Ljava/lang/String;)I
34
- */
35
- JNIEXPORT jint JNICALL Java_com_apple_dnssd_AppleDNSSD_ConstructName
36
- (JNIEnv *, jobject, jstring, jstring, jstring, jobjectArray);
37
-
38
- /*
39
- * Class: com_apple_dnssd_AppleDNSSD
40
- * Method: ReconfirmRecord
41
- * Signature: (IILjava/lang/String;II[B)V
42
- */
43
- JNIEXPORT void JNICALL Java_com_apple_dnssd_AppleDNSSD_ReconfirmRecord
44
- (JNIEnv *, jobject, jint, jint, jstring, jint, jint, jbyteArray);
45
-
46
- /*
47
- * Class: com_apple_dnssd_AppleDNSSD
48
- * Method: GetNameForIfIndex
49
- * Signature: (I)Ljava/lang/String;
50
- */
51
- JNIEXPORT jstring JNICALL Java_com_apple_dnssd_AppleDNSSD_GetNameForIfIndex
52
- (JNIEnv *, jobject, jint);
53
-
54
- /*
55
- * Class: com_apple_dnssd_AppleDNSSD
56
- * Method: GetIfIndexForName
57
- * Signature: (Ljava/lang/String;)I
58
- */
59
- JNIEXPORT jint JNICALL Java_com_apple_dnssd_AppleDNSSD_GetIfIndexForName
60
- (JNIEnv *, jobject, jstring);
61
-
62
- /*
63
- * Class: com_apple_dnssd_AppleDNSSD
64
- * Method: InitLibrary
65
- * Signature: (I)I
66
- */
67
- JNIEXPORT jint JNICALL Java_com_apple_dnssd_AppleDNSSD_InitLibrary
68
- (JNIEnv *, jclass, jint);
69
-
70
- #ifdef __cplusplus
71
- }
72
- #endif
73
- #endif
74
- /* Header for class com_apple_dnssd_AppleBrowser */
75
-
76
- #ifndef _Included_com_apple_dnssd_AppleBrowser
77
- #define _Included_com_apple_dnssd_AppleBrowser
78
- #ifdef __cplusplus
79
- extern "C" {
80
- #endif
81
- /*
82
- * Class: com_apple_dnssd_AppleBrowser
83
- * Method: CreateBrowser
84
- * Signature: (IILjava/lang/String;Ljava/lang/String;)I
85
- */
86
- JNIEXPORT jint JNICALL Java_com_apple_dnssd_AppleBrowser_CreateBrowser
87
- (JNIEnv *, jobject, jint, jint, jstring, jstring);
88
-
89
- #ifdef __cplusplus
90
- }
91
- #endif
92
- #endif
93
- /* Header for class com_apple_dnssd_AppleResolver */
94
-
95
- #ifndef _Included_com_apple_dnssd_AppleResolver
96
- #define _Included_com_apple_dnssd_AppleResolver
97
- #ifdef __cplusplus
98
- extern "C" {
99
- #endif
100
- /*
101
- * Class: com_apple_dnssd_AppleResolver
102
- * Method: CreateResolver
103
- * Signature: (IILjava/lang/String;Ljava/lang/String;Ljava/lang/String;)I
104
- */
105
- JNIEXPORT jint JNICALL Java_com_apple_dnssd_AppleResolver_CreateResolver
106
- (JNIEnv *, jobject, jint, jint, jstring, jstring, jstring);
107
-
108
- #ifdef __cplusplus
109
- }
110
- #endif
111
- #endif
112
- /* Header for class com_apple_dnssd_AppleRegistration */
113
-
114
- #ifndef _Included_com_apple_dnssd_AppleRegistration
115
- #define _Included_com_apple_dnssd_AppleRegistration
116
- #ifdef __cplusplus
117
- extern "C" {
118
- #endif
119
- /*
120
- * Class: com_apple_dnssd_AppleRegistration
121
- * Method: BeginRegister
122
- * Signature: (IILjava/lang/String;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;I[B)I
123
- */
124
- JNIEXPORT jint JNICALL Java_com_apple_dnssd_AppleRegistration_BeginRegister
125
- (JNIEnv *, jobject, jint, jint, jstring, jstring, jstring, jstring, jint, jbyteArray);
126
-
127
- /*
128
- * Class: com_apple_dnssd_AppleRegistration
129
- * Method: AddRecord
130
- * Signature: (II[BILcom/apple/dnssd/AppleDNSRecord;)I
131
- */
132
- JNIEXPORT jint JNICALL Java_com_apple_dnssd_AppleRegistration_AddRecord
133
- (JNIEnv *, jobject, jint, jint, jbyteArray, jint, jobject);
134
-
135
- #ifdef __cplusplus
136
- }
137
- #endif
138
- #endif
139
- /* Header for class com_apple_dnssd_AppleQuery */
140
-
141
- #ifndef _Included_com_apple_dnssd_AppleQuery
142
- #define _Included_com_apple_dnssd_AppleQuery
143
- #ifdef __cplusplus
144
- extern "C" {
145
- #endif
146
- /*
147
- * Class: com_apple_dnssd_AppleQuery
148
- * Method: CreateQuery
149
- * Signature: (IILjava/lang/String;II)I
150
- */
151
- JNIEXPORT jint JNICALL Java_com_apple_dnssd_AppleQuery_CreateQuery
152
- (JNIEnv *, jobject, jint, jint, jstring, jint, jint);
153
-
154
- #ifdef __cplusplus
155
- }
156
- #endif
157
- #endif
158
- /* Header for class com_apple_dnssd_AppleDomainEnum */
159
-
160
- #ifndef _Included_com_apple_dnssd_AppleDomainEnum
161
- #define _Included_com_apple_dnssd_AppleDomainEnum
162
- #ifdef __cplusplus
163
- extern "C" {
164
- #endif
165
- /*
166
- * Class: com_apple_dnssd_AppleDomainEnum
167
- * Method: BeginEnum
168
- * Signature: (II)I
169
- */
170
- JNIEXPORT jint JNICALL Java_com_apple_dnssd_AppleDomainEnum_BeginEnum
171
- (JNIEnv *, jobject, jint, jint);
172
-
173
- #ifdef __cplusplus
174
- }
175
- #endif
176
- #endif
177
- /* Header for class com_apple_dnssd_AppleService */
178
-
179
- #ifndef _Included_com_apple_dnssd_AppleService
180
- #define _Included_com_apple_dnssd_AppleService
181
- #ifdef __cplusplus
182
- extern "C" {
183
- #endif
184
- /*
185
- * Class: com_apple_dnssd_AppleService
186
- * Method: BlockForData
187
- * Signature: ()I
188
- */
189
- JNIEXPORT jint JNICALL Java_com_apple_dnssd_AppleService_BlockForData
190
- (JNIEnv *, jobject);
191
-
192
- /*
193
- * Class: com_apple_dnssd_AppleService
194
- * Method: ProcessResults
195
- * Signature: ()I
196
- */
197
- JNIEXPORT jint JNICALL Java_com_apple_dnssd_AppleService_ProcessResults
198
- (JNIEnv *, jobject);
199
-
200
- /*
201
- * Class: com_apple_dnssd_AppleService
202
- * Method: HaltOperation
203
- * Signature: ()V
204
- */
205
- JNIEXPORT void JNICALL Java_com_apple_dnssd_AppleService_HaltOperation
206
- (JNIEnv *, jobject);
207
-
208
- #ifdef __cplusplus
209
- }
210
- #endif
211
- #endif
212
- /* Header for class com_apple_dnssd_AppleDNSRecord */
213
-
214
- #ifndef _Included_com_apple_dnssd_AppleDNSRecord
215
- #define _Included_com_apple_dnssd_AppleDNSRecord
216
- #ifdef __cplusplus
217
- extern "C" {
218
- #endif
219
- /*
220
- * Class: com_apple_dnssd_AppleDNSRecord
221
- * Method: Update
222
- * Signature: (I[BI)I
223
- */
224
- JNIEXPORT jint JNICALL Java_com_apple_dnssd_AppleDNSRecord_Update
225
- (JNIEnv *, jobject, jint, jbyteArray, jint);
226
-
227
- /*
228
- * Class: com_apple_dnssd_AppleDNSRecord
229
- * Method: Remove
230
- * Signature: ()I
231
- */
232
- JNIEXPORT jint JNICALL Java_com_apple_dnssd_AppleDNSRecord_Remove
233
- (JNIEnv *, jobject);
234
-
235
- #ifdef __cplusplus
236
- }
237
- #endif
238
- #endif
239
- /* Header for class com_apple_dnssd_AppleRecordRegistrar */
240
-
241
- #ifndef _Included_com_apple_dnssd_AppleRecordRegistrar
242
- #define _Included_com_apple_dnssd_AppleRecordRegistrar
243
- #ifdef __cplusplus
244
- extern "C" {
245
- #endif
246
- /*
247
- * Class: com_apple_dnssd_AppleRecordRegistrar
248
- * Method: CreateConnection
249
- * Signature: ()I
250
- */
251
- JNIEXPORT jint JNICALL Java_com_apple_dnssd_AppleRecordRegistrar_CreateConnection
252
- (JNIEnv *, jobject);
253
-
254
- /*
255
- * Class: com_apple_dnssd_AppleRecordRegistrar
256
- * Method: RegisterRecord
257
- * Signature: (IILjava/lang/String;II[BILcom/apple/dnssd/AppleDNSRecord;)I
258
- */
259
- JNIEXPORT jint JNICALL Java_com_apple_dnssd_AppleRecordRegistrar_RegisterRecord
260
- (JNIEnv *, jobject, jint, jint, jstring, jint, jint, jbyteArray, jint, jobject);
261
-
262
- /*
263
- * Class: com_apple_dnssd_DNSSDEmbedded
264
- * Method: Init
265
- * Signature: ()I
266
- */
267
- JNIEXPORT jint JNICALL Java_com_apple_dnssd_DNSSDEmbedded_Init
268
- (JNIEnv *, jclass);
269
-
270
-
271
- /*
272
- * Class: com_apple_dnssd_DNSSDEmbedded
273
- * Method: Init
274
- * Signature: ()I
275
- */
276
- JNIEXPORT jint JNICALL Java_com_apple_dnssd_DNSSDEmbedded_Loop
277
- (JNIEnv *, jclass);
278
-
279
- /*
280
- * Class: com_apple_dnssd_DNSSDEmbedded
281
- * Method: Exit
282
- * Signature: ()V
283
- */
284
- JNIEXPORT void JNICALL Java_com_apple_dnssd_DNSSDEmbedded_Exit
285
- (JNIEnv *, jclass);
286
-
287
- #ifdef __cplusplus
288
- }
289
- #endif
290
- #endif