Calculi for Network Aware Programming