Template-based AADL automatic code generation