Home
last modified time | relevance | path

Searched refs:MdnsUtils (Results 1 – 25 of 28) sorted by relevance

12

/packages/modules/Connectivity/tests/unit/java/com/android/server/connectivity/mdns/util/
DMdnsUtilsTest.kt26 import com.android.server.connectivity.mdns.util.MdnsUtils.createQueryDatagramPackets in <lambda>()
27 import com.android.server.connectivity.mdns.util.MdnsUtils.equalsDnsLabelIgnoreDnsCase in <lambda>()
28 import com.android.server.connectivity.mdns.util.MdnsUtils.equalsIgnoreDnsCase in <lambda>()
29 import com.android.server.connectivity.mdns.util.MdnsUtils.toDnsLabelsLowerCase in <lambda>()
30 import com.android.server.connectivity.mdns.util.MdnsUtils.toDnsLowerCase in <lambda>()
31 import com.android.server.connectivity.mdns.util.MdnsUtils.truncateServiceName in <lambda>()
116 assertTrue(MdnsUtils.typeEqualsOrIsSubtype( in <lambda>()
120 assertTrue(MdnsUtils.typeEqualsOrIsSubtype( in <lambda>()
124 assertFalse(MdnsUtils.typeEqualsOrIsSubtype( in <lambda>()
128 assertFalse(MdnsUtils.typeEqualsOrIsSubtype( in <lambda>()
/packages/modules/Connectivity/service-t/src/com/android/server/connectivity/mdns/
DMdnsResponseDecoder.java25 import com.android.server.connectivity.mdns.util.MdnsUtils;
40 private final MdnsUtils.Clock clock;
43 public MdnsResponseDecoder(@NonNull MdnsUtils.Clock clock, @Nullable String[] serviceType) { in MdnsResponseDecoder()
52 if (MdnsUtils.equalsDnsLabelIgnoreDnsCase(response.getServiceName(), pointer)) { in findResponseWithPointer()
68 if (MdnsUtils.equalsDnsLabelIgnoreDnsCase(serviceRecord.getServiceHost(), in findResponseWithHostName()
139 final Set<MdnsResponse> modified = MdnsUtils.newSet(); in augmentResponses()
175 if ((serviceType == null) || MdnsUtils.typeEqualsOrIsSubtype( in augmentResponses()
321 if (MdnsUtils.equalsDnsLabelIgnoreDnsCase(serviceRecord.getServiceHost(), hostName)) { in findResponsesWithHostName()
DMdnsPointerRecord.java23 import com.android.server.connectivity.mdns.util.MdnsUtils;
71 return (name != null) && (name.length > 2) && MdnsUtils.equalsIgnoreDnsCase(name[1], in hasSubtype()
86 return (super.hashCode() * 31) + Arrays.hashCode(MdnsUtils.toDnsLabelsLowerCase(pointer)); in hashCode()
98 return super.equals(other) && MdnsUtils.equalsDnsLabelIgnoreDnsCase(pointer, in equals()
DMdnsServiceCache.java20 import static com.android.server.connectivity.mdns.util.MdnsUtils.ensureRunningOnHandlerThread;
21 import static com.android.server.connectivity.mdns.util.MdnsUtils.equalsIgnoreDnsCase;
22 import static com.android.server.connectivity.mdns.util.MdnsUtils.toDnsLowerCase;
33 import com.android.server.connectivity.mdns.util.MdnsUtils;
95 private final MdnsUtils.Clock mClock;
99 this(looper, mdnsFeatureFlags, new MdnsUtils.Clock()); in MdnsServiceCache()
104 @NonNull MdnsUtils.Clock clock) { in MdnsServiceCache()
DEnqueueMdnsQueryCallable.java28 import com.android.server.connectivity.mdns.util.MdnsUtils;
78 private final MdnsUtils.Clock clock;
99 @NonNull MdnsUtils.Clock clock, in EnqueueMdnsQueryCallable()
155 boolean renewTxt = !response.hasTextRecord() || MdnsUtils.isRecordRenewalNeeded( in call()
157 boolean renewSrv = !response.hasServiceRecord() || MdnsUtils.isRecordRenewalNeeded( in call()
196 && MdnsUtils.equalsDnsLabelIgnoreDnsCase( in call()
DMdnsRecord.java28 import com.android.server.connectivity.mdns.util.MdnsUtils;
142 if (!MdnsUtils.equalsIgnoreDnsCase(list1[i], list2[i + offset])) { in labelsAreSuffix()
287 return MdnsUtils.equalsDnsLabelIgnoreDnsCase(name, otherRecord.name) && (type in equals()
293 return Objects.hash(Arrays.hashCode(MdnsUtils.toDnsLabelsLowerCase(name)), type); in hashCode()
314 this.recordName = MdnsUtils.toDnsLabelsLowerCase(recordName); in Key()
DMdnsServiceTypeClient.java21 import static com.android.server.connectivity.mdns.util.MdnsUtils.Clock;
22 import static com.android.server.connectivity.mdns.util.MdnsUtils.ensureRunningOnHandlerThread;
37 import com.android.server.connectivity.mdns.util.MdnsUtils;
114 ? MdnsUtils.newSet() : previousInfo.discoveredServiceNames; in ListenerInfo()
123 return discoveredServiceNames.add(MdnsUtils.toDnsLowerCase(serviceName)); in setServiceDiscovered()
127 discoveredServiceNames.remove(MdnsUtils.toDnsLowerCase(serviceName)); in unsetServiceDiscovered()
241 return MdnsUtils.createQueryDatagramPackets(packetCreationBuffer, packet, address); in getDatagramPacketsFromMdnsPacket()
244 MdnsUtils.createRawDnsPacket(packetCreationBuffer, packet); in getDatagramPacketsFromMdnsPacket()
435 final Set<String> subtypes = MdnsUtils.newSet(); in getAllDiscoverySubtypes()
461 || MdnsUtils.equalsIgnoreDnsCase(options.getResolveInstanceName(), in responseMatchesOptions()
[all …]
DMulticastPacketReader.java19 import static com.android.server.connectivity.mdns.util.MdnsUtils.ensureRunningOnHandlerThread;
27 import com.android.server.connectivity.mdns.util.MdnsUtils;
42 private final Set<PacketHandler> mPacketHandlers = MdnsUtils.newSet();
DMdnsServiceRecord.java23 import com.android.server.connectivity.mdns.util.MdnsUtils;
154 Arrays.hashCode(MdnsUtils.toDnsLabelsLowerCase(serviceHost)), in hashCode()
171 && MdnsUtils.equalsDnsLabelIgnoreDnsCase(serviceHost, otherRecord.serviceHost) in equals()
DMdnsAdvertiser.java46 import com.android.server.connectivity.mdns.util.MdnsUtils;
275 return MdnsUtils.equalsIgnoreDnsCase(newInfo.getHostname(), mDeviceHostName[0]); in hasAnyHostConflict()
439 if (MdnsUtils.equalsIgnoreDnsCase(info.getServiceName(), other.getServiceName()) in getConflictingRegistrationDueToService()
440 && MdnsUtils.equalsIgnoreDnsCase(info.getServiceType(), in getConflictingRegistrationDueToService()
466 && MdnsUtils.equalsIgnoreDnsCase( in getConflictingRegistrationDueToHost()
472 && MdnsUtils.equalsIgnoreDnsCase( in getConflictingRegistrationDueToHost()
724 final String truncatedServiceName = MdnsUtils.truncateServiceName(mOriginalServiceName, in getUpdatedServiceName()
732 MdnsUtils.truncateServiceName( in getUpdatedHostname()
852 priorities.put(MdnsUtils.toDnsLowerCase(priorityAndType[1]), priority); in parseOffloadPriorityList()
998 MdnsUtils.toDnsLowerCase(nsdServiceInfo.getServiceType())); in createOffloadService()
DExecutorProvider.java21 import com.android.server.connectivity.mdns.util.MdnsUtils;
34 MdnsUtils.newSet();
DMdnsDiscoveryManager.java34 import com.android.server.connectivity.mdns.util.MdnsUtils;
69 final String dnsLowerServiceType = MdnsUtils.toDnsLowerCase(serviceType); in put()
78 final String dnsLowerServiceType = MdnsUtils.toDnsLowerCase(serviceType); in get()
85 final String dnsLowerServiceType = MdnsUtils.toDnsLowerCase(serviceType); in getByServiceType()
199 MdnsUtils.ensureRunningOnHandlerThread(handler); in ensureRunningOnHandlerThread()
DMdnsNsecRecord.java23 import com.android.server.connectivity.mdns.util.MdnsUtils;
156 Arrays.hashCode(MdnsUtils.toDnsLabelsLowerCase(mNextDomain)), in hashCode()
170 && MdnsUtils.equalsDnsLabelIgnoreDnsCase(mNextDomain, in equals()
DMdnsResponse.java24 import com.android.server.connectivity.mdns.util.MdnsUtils;
114 if (!MdnsUtils.equalsDnsLabelIgnoreDnsCase(serviceName, pointerRecord.getPointer())) { in addPointerRecord()
308 if (!MdnsUtils.equalsDnsLabelIgnoreDnsCase( in dropUnmatchedAddressRecords()
314 if (!MdnsUtils.equalsDnsLabelIgnoreDnsCase( in dropUnmatchedAddressRecords()
DMdnsProber.java27 import com.android.server.connectivity.mdns.util.MdnsUtils;
117 r -> MdnsUtils.equalsDnsLabelIgnoreDnsCase(name, r.getName())); in containsName()
DMdnsReplySender.java21 import static com.android.server.connectivity.mdns.util.MdnsUtils.ensureRunningOnHandlerThread;
34 import com.android.server.connectivity.mdns.util.MdnsUtils;
213 final byte[] outBuffer = MdnsUtils.createRawDnsPacket(mPacketCreationBuffer, packet); in sendNow()
DMdnsRecordRepository.java42 import com.android.server.connectivity.mdns.util.MdnsUtils;
286 MdnsUtils.constructFullSubtype(serviceType, subtype), in ServiceRegistration()
497 if (MdnsUtils.equalsIgnoreDnsCase(serviceName, info.getServiceName()) in getServiceByNameAndType()
498 && MdnsUtils.equalsIgnoreDnsCase(serviceType, info.getServiceType())) { in getServiceByNameAndType()
824 if (!MdnsUtils.equalsDnsLabelIgnoreDnsCase(info.record.getName(), question.getName())) { in addReplyFromService()
1235 if (!MdnsUtils.equalsDnsLabelIgnoreDnsCase(record.getName(), fullServiceName)) { in conflictForService()
1273 if (!MdnsUtils.equalsIgnoreDnsCase( in conflictForHost()
1354 if (MdnsUtils.equalsIgnoreDnsCase(service.serviceInfo.getHostname(), hostname)) { in forEachActiveServiceRegistrationWithHostname()
DMdnsSearchOptions.java26 import com.android.server.connectivity.mdns.util.MdnsUtils;
215 subtypes = MdnsUtils.newSet(); in Builder()
DMdnsPacketWriter.java20 import com.android.server.connectivity.mdns.util.MdnsUtils;
183 if (MdnsUtils.equalsDnsLabelIgnoreDnsCase(existingLabels, labels)) { in writeLabels()
DMdnsInterfaceAdvertiser.java35 import com.android.server.connectivity.mdns.util.MdnsUtils;
463 return MdnsUtils.createRawDnsPacket(mPacketCreationBuffer, in getRawOffloadPayload()
DMdnsMultinetworkSocketClient.java19 import static com.android.server.connectivity.mdns.util.MdnsUtils.ensureRunningOnHandlerThread;
DMdnsSocketProvider.java22 import static com.android.server.connectivity.mdns.util.MdnsUtils.ensureRunningOnHandlerThread;
23 import static com.android.server.connectivity.mdns.util.MdnsUtils.isNetworkMatched;
/packages/modules/Connectivity/service-t/src/com/android/server/connectivity/mdns/util/
DMdnsUtils.java53 public class MdnsUtils { class
55 private MdnsUtils() { } in MdnsUtils() method in MdnsUtils
137 return MdnsUtils.equalsDnsLabelIgnoreDnsCase(a, b) in typeEqualsOrIsSubtype()
139 && MdnsUtils.equalsIgnoreDnsCase(b[1], MdnsConstants.SUBTYPE_LABEL) in typeEqualsOrIsSubtype()
/packages/modules/Connectivity/tests/unit/java/com/android/server/connectivity/mdns/
DMdnsServiceCacheTest.kt25 import com.android.server.connectivity.mdns.util.MdnsUtils in <lambda>()
60 private val clock = mock(MdnsUtils.Clock::class.java) in <lambda>()
/packages/modules/Connectivity/service-t/src/com/android/server/
DNsdService.java41 import static com.android.server.connectivity.mdns.util.MdnsUtils.Clock;
111 import com.android.server.connectivity.mdns.util.MdnsUtils;
733 return MdnsUtils.truncateServiceName(originalName, MAX_LABEL_LENGTH); in truncateServiceName()
771 subtypeMap.put(MdnsUtils.toDnsLowerCase(subtype), subtype); in dedupSubtypeLabels()
2975 if (MdnsUtils.isAnyNetworkMatched(reqNetwork, networks)) { in hasAnyJavaBackendRequestForNetworks()

12