Add setAttr and getAttr

Signed-off-by: Daniel Francis <francis@sugarlabs.org>