DishSocket.cs 949 B

1234567891011121314151617181920212223242526272829303132333435
  1. namespace NetMQ.Sockets
  2. {
  3. /// <summary>
  4. /// Dish socket, thread-safe alternative for SUB socket
  5. /// </summary>
  6. public class DishSocket : ThreadSafeSocket, IGroupInSocket
  7. {
  8. /// <summary>
  9. /// Create a new Client Socket.
  10. /// </summary>
  11. public DishSocket() : base(ZmqSocketType.Dish)
  12. {
  13. }
  14. /// <summary>
  15. /// Join the dish socket to a group
  16. /// </summary>
  17. /// <param name="group">The group to join</param>
  18. public void Join(string group)
  19. {
  20. m_socketHandle.CheckDisposed();
  21. m_socketHandle.Join(group);
  22. }
  23. /// <summary>
  24. /// Leave a group for a dish socket
  25. /// </summary>
  26. /// <param name="group">The group leave</param>
  27. public void Leave(string group)
  28. {
  29. m_socketHandle.CheckDisposed();
  30. m_socketHandle.Leave(group);
  31. }
  32. }
  33. }