Computer (Peripheral) documentation

Introductions

Computer are not only able to receive peripherals, but are themselves peripherals, and allow computers to control each other and even preform basic communication.

Note: that state changing commands might not be applied instantly, and programs should check before making assumptions about the state of a computer being controlled

Note the second: the UUID of the peripheral is the exact same as the UUID for the computer, literally the exact same.

All Computers are categorized as "neetcomputers:computer" in the IO API

Lookup table

shutdown() Instructs the computer to shut down at its nearest convenience
startup() Instructs the computer to startup at its nearest convenience
getId() Gets the UUID of the computer
getMachine() Gets a string definition of the type of the computer
isOn() Checks if the computer is on
notify(...) Sends message to computer

Functions in detail

shutdown()

Tells the targeted computer to shut down, not instant.

Parameters: None Returns: None

startup()

Tells the targeted computer to power up, is instant but the computer won't be ready to run code instantly.

Parameters: None Returns: None

getId()

Gets the UUID of the computer.

Parameters: None Returns: String

getMachine()

Gets a string definition of the type of the computer.

Parameters: None Returns: String

isOn()

Checks if the computer is on.

Parameters: None Returns: Boolean