/packages/services/Car/tests/carservice_test/src/com/android/car/ |
D | VmsPublisherSubscriberTest.java | 77 int publisherId = mPublisher.getPublisherId(PUBLISHER_INFO); in testPublisherInfo_Registered() local 78 assertArrayEquals(PUBLISHER_INFO, mSubscriber.getPublisherInfo(publisherId)); in testPublisherInfo_Registered() 83 int publisherId = mPublisher.getPublisherId(PUBLISHER_INFO); in testPublisherId_AlreadyRegistered() local 85 assertEquals(publisherId, publisherId2); in testPublisherId_AlreadyRegistered() 90 int publisherId = mPublisher.getPublisherId(PUBLISHER_INFO); in testPublisherId_MultiplePublishers() local 92 assertNotEquals(publisherId, publisherId2); in testPublisherId_MultiplePublishers() 93 assertArrayEquals(PUBLISHER_INFO, mSubscriber.getPublisherInfo(publisherId)); in testPublisherId_MultiplePublishers() 106 int publisherId = mPublisher.getPublisherId(PUBLISHER_INFO); in testLayerAvailability() local 108 new VmsLayerDependency(SUBSCRIPTION_LAYER, Collections.emptySet())), publisherId)); in testLayerAvailability() 111 new VmsAssociatedLayer(SUBSCRIPTION_LAYER, Collections.singleton(publisherId))); in testLayerAvailability() [all …]
|
/packages/services/Car/service/src/com/android/car/ |
D | VmsPublishersInfo.java | 69 Integer publisherId; in getIdForInfo() local 73 publisherId = mPublishersIds.get(wrappedPublisherInfo); in getIdForInfo() 74 if (publisherId == null) { in getIdForInfo() 77 publisherId = mPublishersInfo.size(); in getIdForInfo() 78 mPublishersIds.put(wrappedPublisherInfo, publisherId); in getIdForInfo() 81 return publisherId; in getIdForInfo() 89 public byte[] getPublisherInfo(int publisherId) { in getPublisherInfo() argument 91 return publisherId < 1 || publisherId > mPublishersInfo.size() in getPublisherInfo() 93 : mPublishersInfo.get(publisherId - 1).getInfo(); in getPublisherInfo()
|
D | VmsRouting.java | 149 public void addSubscription(IVmsSubscriberClient subscriber, VmsLayer layer, int publisherId) { in addSubscription() argument 154 .computeIfAbsent(publisherId, k -> new ArraySet<>()); in addSubscription() 172 int publisherId) { in removeSubscription() argument 179 subscribersToPublishers.getOrDefault(publisherId, Collections.emptySet()); in removeSubscription() 187 subscribersToPublishers.remove(publisherId); in removeSubscription() 246 int publisherId) { in getSubscribersForLayerFromPublisher() argument 258 .getOrDefault(publisherId, Collections.emptySet())); in getSubscribersForLayerFromPublisher() 278 public boolean hasLayerFromPublisherSubscriptions(VmsLayer layer, int publisherId) { in hasLayerFromPublisherSubscriptions() argument 282 .containsKey(publisherId); in hasLayerFromPublisherSubscriptions()
|
D | VmsSubscriberService.java | 99 int publisherId) { in addVmsSubscriberToPublisher() argument 102 mBrokerService.addSubscription(subscriber, layer, publisherId); in addVmsSubscriberToPublisher() 108 int publisherId) { in removeVmsSubscriberToPublisher() argument 110 mBrokerService.removeSubscription(subscriber, layer, publisherId); in removeVmsSubscriberToPublisher() 127 public byte[] getPublisherInfo(int publisherId) { in getPublisherInfo() argument 129 return mBrokerService.getPublisherInfo(publisherId); in getPublisherInfo()
|
D | VmsPublisherService.java | 173 public void publish(IBinder token, VmsLayer layer, int publisherId, byte[] payload) { in publish() argument 176 Log.d(TAG, String.format("Publishing to %s as %d (%s)", layer, publisherId, mName)); in publish() 189 mBrokerService.getSubscribersForLayerFromPublisher(layer, publisherId); in publish()
|
/packages/services/Car/service/src/com/android/car/vms/ |
D | VmsBrokerService.java | 197 public void addSubscription(IVmsSubscriberClient subscriber, VmsLayer layer, int publisherId) { in addSubscription() argument 202 || mRouting.hasLayerFromPublisherSubscriptions(layer, publisherId)); in addSubscription() 205 mRouting.addSubscription(subscriber, layer, publisherId); in addSubscription() 220 int publisherId) { in removeSubscription() argument 223 if (!mRouting.hasLayerFromPublisherSubscriptions(layer, publisherId)) { in removeSubscription() 226 + layer + ", publisher ID:" + publisherId); in removeSubscription() 232 mRouting.removeSubscription(subscriber, layer, publisherId); in removeSubscription() 236 || mRouting.hasLayerFromPublisherSubscriptions(layer, publisherId); in removeSubscription() 265 int publisherId) { in getSubscribersForLayerFromPublisher() argument 267 return mRouting.getSubscribersForLayerFromPublisher(layer, publisherId); in getSubscribersForLayerFromPublisher() [all …]
|
/packages/services/Car/car-lib/src/android/car/vms/ |
D | VmsSubscriberManager.java | 174 public byte[] getPublisherInfo(int publisherId) { in getPublisherInfo() argument 176 return mVmsSubscriberService.getPublisherInfo(publisherId); in getPublisherInfo() 221 public void subscribe(@NonNull VmsLayer layer, int publisherId) { in subscribe() argument 225 mSubscriberManagerClient, layer, publisherId); in subscribe() 226 VmsOperationRecorder.get().subscribe(layer, publisherId); in subscribe() 270 public void unsubscribe(@NonNull VmsLayer layer, int publisherId) { in unsubscribe() argument 273 mSubscriberManagerClient, layer, publisherId); in unsubscribe() 274 VmsOperationRecorder.get().unsubscribe(layer, publisherId); in unsubscribe()
|
D | VmsPublisherClientService.java | 114 public final void publish(@NonNull VmsLayer layer, int publisherId, byte[] payload) { in publish() argument 121 mVmsPublisherService.publish(token, layer, publisherId, payload); in publish() 176 int publisherId; in getPublisherId() local 178 publisherId = mVmsPublisherService.getPublisherId(publisherInfo); in getPublisherId() 179 Log.i(TAG, "Assigned publisher ID: " + publisherId); in getPublisherId() 184 VmsOperationRecorder.get().getPublisherId(publisherId); in getPublisherId() 185 return publisherId; in getPublisherId()
|
D | VmsOperationRecorder.java | 54 public void subscribe(VmsLayer layer, int publisherId) { in subscribe() argument 55 recordOp("subscribe", "publisherId", publisherId, layer); in subscribe() 58 public void unsubscribe(VmsLayer layer, int publisherId) { in unsubscribe() argument 59 recordOp("unsubscribe", "publisherId", publisherId, layer); in unsubscribe() 74 public void getPublisherId(int publisherId) { in getPublisherId() argument 75 recordOp("getPublisherId", "publisherId", publisherId); in getPublisherId()
|
D | IVmsSubscriberService.aidl | 55 int publisherId) = 3; in addVmsSubscriberToPublisher() argument 86 int publisherId) = 7; in removeVmsSubscriberToPublisher() argument 96 byte[] getPublisherInfo(in int publisherId) = 9; in getPublisherInfo() argument
|
D | VmsLayersOffering.java | 52 public VmsLayersOffering(@NonNull Set<VmsLayerDependency> dependencies, int publisherId) { in VmsLayersOffering() argument 54 mPublisherId = publisherId; in VmsLayersOffering()
|
D | IVmsPublisherService.aidl | 32 … oneway void publish(in IBinder token, in VmsLayer layer, int publisherId, in byte[] message) = 0; in publish() argument
|
/packages/services/Car/service/src/com/android/car/hal/ |
D | VmsHalService.java | 464 int publisherId = parsePublisherIdFromMessage(message); in handleDataEvent() local 467 "Handling a data event for Layer: " + vmsLayer + " Publisher: " + publisherId); in handleDataEvent() 469 mPublisherService.publish(mPublisherToken, vmsLayer, publisherId, payload); in handleDataEvent() 500 int publisherId = parsePublisherIdFromMessage(message); in handleSubscribeToPublisherEvent() local 504 + publisherId); in handleSubscribeToPublisherEvent() 506 mSubscriberService.addVmsSubscriberToPublisher(mSubscriberClient, vmsLayer, publisherId); in handleSubscribeToPublisherEvent() 537 int publisherId = parsePublisherIdFromMessage(message); in handleUnsubscribeFromPublisherEvent() local 540 + publisherId); in handleUnsubscribeFromPublisherEvent() 542 mSubscriberService.removeVmsSubscriberToPublisher(mSubscriberClient, vmsLayer, publisherId); in handleUnsubscribeFromPublisherEvent() 586 int publisherId = message.get(VmsPublisherInformationIntegerValuesIndex.PUBLISHER_ID); in handlePublisherInfoRequest() local [all …]
|
/packages/services/Car/tests/carservice_unit_test/src/com/android/car/ |
D | VmsRoutingTest.java | 870 private void assertNoSubscribers(VmsLayer layer, int publisherId) { in assertNoSubscribers() argument 871 assertSubscribers(layer, publisherId); /* subscribers is empty */ in assertNoSubscribers() 881 for (int publisherId : PUBLISHER_IDS) { in assertSubscribers() 882 assertSubscribers(layer, publisherId, subscribers); in assertSubscribers() 886 private void assertSubscribers(VmsLayer layer, int publisherId, in assertSubscribers() argument 890 mRouting.getSubscribersForLayerFromPublisher(layer, publisherId)); in assertSubscribers()
|