Adaptive Service-Oriented Mobile Applications: A Declarative Approach