Class ChannelSender
Definition
- Assembly:
- Tizen.Core.dll
Represents the channel sender used for inter-task communication. It provides methods to send messages between tasks in order to facilitate task coordination.
public class ChannelSender : IDisposable
- Inheritance
-
objectChannelSender
Methods
View SourceClone()
Creates and returns a copy of the channel sender object.
Declaration
public ChannelSender Clone()
Returns
| Type | Description |
|---|---|
| ChannelSender | A newly created channel sender instance. |
Examples
var channel = new Channel();
var sender = channel.Sender;
var clonedSender = sender.Clone();
View Source
Dispose()
Release any unmanaged resources used by this object.
Declaration
public void Dispose()
Dispose(bool)
Release any unmanaged resources used by this object.
Declaration
protected virtual void Dispose(bool disposing)
Parameters
| Type | Name | Description |
|---|---|---|
| bool | disposing | If true, disposes any disposable objects. If false, does not dispose disposable objects. |
~ChannelSender()
Finalizes an instance of the ChannelSender class.
Declaration
protected ~ChannelSender()
Send(ChannelObject)
Sends the channel object to the receiver.
Declaration
public void Send(ChannelObject channelObject)
Parameters
| Type | Name | Description |
|---|---|---|
| ChannelObject | channelObject | The channel object instance. |
Remarks
It's important to call the Dispose() method on the passed channel object to release resources.
Examples
var channel = new Channel();
var sender = channel.Sender;
string message = "Test";
using (var channelObject = new ChannelObject(1, message))
{
sender.Send(channelObject);
}