Context scoping in java