Simplified _set_and_get method.