cc-haxe/src/kernel/net/INetworkInterface.hx

18 lines
496 B
Haxe
Raw Normal View History

2022-02-24 18:47:27 +00:00
package kernel.net;
using tink.CoreApi;
/**
A object that is able to send and receive messages.
**/
interface INetworkInterface {
public function listen(chan: Int):Void;
public function close(chan: Int):Void;
public function isListening(chan: Int): Bool;
public function closeAll(): Void;
public function send(chan: Int,replyChan: Int,payload: Any):Void;
public function name():String;
public function getBaseRoutingCost():Int;
public var onMessage (default, null): Signal<Package>;
}