Plan B User's Manual


selectors ­ Get names for inner boxes.


#include <ulib.h>

void selectors(char* sel, char* buf, int len)


A box may contain inner boxes. Selectors puts into buf at most len bytes with the set of names for inner boxes contained in the box with name and constraint given by sel.

Only top-level names are placed into buf. If several inner boxes have the same name, the name appears once.


selectors("/b/proc!*!p98", p98ones, BUFLEN);
selectors("/b/proc", allofthem, BUFLEN);

The first call would write in p98ones the set of names for p98 processes running, separated by white space. The second call will write all the names, no matter what the architecture is.



See also


Plan B User's Manual. First edition.