|This article does not cite any references or sources. (December 2009)|
In computing, a sink or event sink is a class or function designed to receive incoming events from another object or function. This is commonly implemented in C++ as callbacks. Object-oriented languages, such as Java and C#, have built-in support for sinks by allowing events to be fired to delegate functions.
It can also be considered the end-point or output point. For example, a buffer stream would often have a source (into which the data is put) and a sink (whereto the data is written out). Another way of thinking about it could be like a black hole—the source is where everything goes in and the sink is where it all goes at the other end. This is often seen in C++ and hardware-related programming.
The word sink has been used for both input and output in the industry. Mobile sink is proposed to save sensor energy for multihop communication in transferring data to a base station (sink) in wireless sensor networks
|This computing article is a stub. You can help Wikipedia by expanding it.|