MediateSpace: applying contextual mediation to the tuple space paradigm