com.microsoft.signalr.Subscription Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of signalr Show documentation
Show all versions of signalr Show documentation
ASP.NET Core SignalR Client for Java applications
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
package com.microsoft.signalr;
import java.util.List;
/**
* Represents the registration of a handler for a client method.
*/
public class Subscription {
private final CallbackMap handlers;
private final InvocationHandler handler;
private final String target;
Subscription(CallbackMap handlers, InvocationHandler handler, String target) {
this.handlers = handlers;
this.handler = handler;
this.target = target;
}
/**
* Removes the client method handler represented by this subscription.
*/
public void unsubscribe() {
List handler = this.handlers.get(target);
if (handler != null) {
handler.remove(this.handler);
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy