network.udp · thing ·
udpDatagram
A udp datagram record carrying status, address, port, payload.
Exchange bounded UDP datagrams; your application owns its protocol and session rules.
external thing udpDatagramStatus: source-declared
Fields and methods (8)
int status- Stores status as int.
text address- Stores address as text.
int port- Stores port as int.
list of byte payload- Stores payload as list of byte.
udpDatagram(int status, text address, int port, list of byte payload)- Udp datagram.
Available() returns bool- Available. Complete example
WouldBlock() returns bool- Would block. Complete example
Diagnostic() returns text- Diagnostic. Complete example
Use udpDatagram
A complete small caller. Values are illustrative; check the returned result and package requirements before connecting live resources.
cpu · source-example · type checked
using network.udp
// Exchange bounded UDP datagrams; your application owns its protocol and session rules.
udpDatagram sample = udpDatagram(1, "address", 1, [])
Console.Log(Text.From(sample.status))
project.mech
manifestVersion = "2"
package = "api.example.network_udp__udpdatagram"
version = "0.1.0"
languageEdition = "yeho-core-2026.1"
[app]
kind = "headless"
[[dependencies]]
package = "network.udp"
version = "0.1.0"
path = "../../../yeho/packages/network/udp"
udpDatagram.Available
A complete caller for this public method. Sample inputs are illustrative; native resources require their owning lifecycle.
cpu · method · source-example · type checked
using network.udp
// Available.
udpDatagram instance = udpDatagram(1, "address", 1, [])
bool result = instance.Available()
Console.Log(Text.From(result))
project.mech
manifestVersion = "2"
package = "api.example.network_udp__udpdatagram"
version = "0.1.0"
languageEdition = "yeho-core-2026.1"
[app]
kind = "headless"
[[dependencies]]
package = "network.udp"
version = "0.1.0"
path = "../../../yeho/packages/network/udp"
udpDatagram.WouldBlock
A complete caller for this public method. Sample inputs are illustrative; native resources require their owning lifecycle.
cpu · method · source-example · type checked
using network.udp
// Would block.
udpDatagram instance = udpDatagram(1, "address", 1, [])
bool result = instance.WouldBlock()
Console.Log(Text.From(result))
project.mech
manifestVersion = "2"
package = "api.example.network_udp__udpdatagram"
version = "0.1.0"
languageEdition = "yeho-core-2026.1"
[app]
kind = "headless"
[[dependencies]]
package = "network.udp"
version = "0.1.0"
path = "../../../yeho/packages/network/udp"
udpDatagram.Diagnostic
A complete caller for this public method. Sample inputs are illustrative; native resources require their owning lifecycle.
cpu · method · source-example · type checked
using network.udp
// Diagnostic.
udpDatagram instance = udpDatagram(1, "address", 1, [])
text result = instance.Diagnostic()
Console.Log(Text.From(result))
project.mech
manifestVersion = "2"
package = "api.example.network_udp__udpdatagram"
version = "0.1.0"
languageEdition = "yeho-core-2026.1"
[app]
kind = "headless"
[[dependencies]]
package = "network.udp"
version = "0.1.0"
path = "../../../yeho/packages/network/udp"
Notes and source
Package presence and a declaration do not establish support on every host. Host services need their platform and lifecycle setup.
yeho/packages/network/udp/udp.yh:81