rCOS: a formal model-driven engineering method for component-based software