consolidate class diagram and code