package reader import ( "context" v2 "edge-infra.dev/pkg/sds/display/k8s/apis/v2" ) // A DisplayReader is able to read the current display configuration from the host // node and return it as a DisplayConfig, e.g. by making Xrandr calls to query // the node and representing this as a DisplayConfig. Also returned are a slice // of input devices present on the node. // // The relevant display manager (e.g. Xorg) must be running to be able to query the // node's displays. See manager.DisplayManager. type DisplayReader interface { // Read reads the display configuration from the node, representing it // as a DisplayConfig. Also returns a list of the input devices // available to the display manager. // // By default the reader will query all fields of the DisplayConfig. // Options can be supplied to change the querying behaviour for each // field, e.g. WithDefaultDPMS() will not query the DPMS settings and // return default values. Read(context.Context, ...Option) (*v2.DisplayConfig, []v2.InputDeviceName, error) }