MDA和DSL:生来陌路?

博客围绕MDA和软件工厂展开,介绍了AndroMDA这一用UML和MDA为*nix系统生成J2EE代码的开源工具。指出在MDA中UML类图占主导,且需添加自定义元数据用于代码生成。还探讨了这种方式存在的问题,如知识依赖用户,建议使用领域特定语言。

摘自hawkblog http://devhawk.net/MDA+And+Software+Factories++Separated+At+Birth.aspx

我个人并不赞同他的观点,现存的困难和问题并不能掩盖未来的方向。

为方便查看,原文拷贝如下:

MDA And Software Factories - Separated At Birth?

Tonight I went to the monthly meeting of the local chapter of IASA. I should have also blogged thisbefore the meeting, but I forgot. Sorry about that if you live near the Microsoft campus and wanted to go. Next meeting is on 3/30, so mark your calendars.

Anyway, tonight's topic was an MDA workshop featuring AndroMDA. AndroMDA is an open source tool for generating primarily J2EE code for *nix boxes using UML and MDA. (To be fair, the speaker - local chapter president Chris Sterling - demonstrated generating C# code as well. Of course, he ran it under Mono on a Linux box.) This provided a great launching point for a general modeling discussion that helped me get a few things straight in my head. Typically, the UML vs. DSL discussion turns religious pretty quickly. However, I believe that people - like those a the meeting tonight - who are achieving practical success with MDA in the real world are doing so by using a Software Factories style approach.

First off, if you look at how most people use UML for MDA, the class diagram appears to be the most dominant model used. When I say "UML for MDA", what I mean is people using UML as a blueprintoras aprogramming language.While UML has 12 different model types, class diagrams make up the bulk of the modeling effort. (The bulk of AndroMDA code generation works off the UML class diagram, though the BPM4Struts cartridge uses Use Case & State models as well) The other 11 diagrams are primarily used for sketching purposes. That means you're only blueprinting the structural aspect of your system - which in turn means that all the system's behavior has to be implemented by hand. Now, this is not to say that factories suggests you should only model the structural aspect of your system. However, I think this indicates that most pragmatic users have realized MDA doesn't live up to the hype.

Secondly, the class diagram that are used have tobe heavily adorned with custom metadata - typically in the form of stereotypes - in order to be useful for code generation (i.e. blueprint) purposes. AndroMDA has a set of "cartridges" (essentially, target code generators) such as EJB, Hibernate and POJOs. Each of these cartridges has a supported set of stereotypes. While there is some overlap (for example, EJB and Hibernate cartridges both define the Entity stereotype). These stereotypes assign brand new semantics to the elements being modeled. In short, they turn the the generic class modeler into a domain specific modeler!

It appears to me that the pragmatic MDA crowd is using the class diagram as a generic "ball and stick" editor. Model elements that aren't needed are ignored and elements that are needed are added via stereotypes. For example, you can use a class diagram to model a database. Certain elements of the model are ignored (Can a column have protected visibility? Can one table inherit from another?) while other elements specific to the domain being modeled are added (primary and foreign keys, indexes, etc). The problem with this approach is that all of the knowledge of how to build a valid model is in the user's head, rather than the tool. Typically, that means a lot of training as well as a lot of in depth understanding of the framework underlying the model in order to capture the right amount of information. Since all that domain specific information is trapped in the users head, they have to do a ton of menial drudge work. It's different drudge work from things like writing tons of data access code, but it's drudgery nonetheless.

If you're going to need a tool specifically designed for your problem domain, why use a generic tool and a bunch of handwritten rules, when you can codify those rules into a domain specific language of your own? (I mean, other than the obvious "because the DSL Toolkit hasn't shipped yet")

Beyond Compare是一款文件差异比较工具的文件文件夹比较工具,使用该工具可以可视化调整差异, 合并修改,同步文件夹。支持文件夹比较,文件夹合并同步,文本比较,表格比较,图片比较,16进制比较,注册表比较,版本比较等;调整差异,合并修改,内置文件浏览器可以针对文件、文件夹之间的差异对比及上传同步。 Beyond Compare 5.0.4.30422是一款先进的文件文件夹比较工具,它能够帮助用户高效地识别管理文件差异,支持多种文件类型格式的比较。使用Beyond Compare,用户可以轻松地对文件夹内容进行同步,无论是进行简单的文件复制还是复杂的项目同步任务。此外,该工具还具备了高级的文件比较功能,如文本比较、表格比较、图片比较、16进制比较以及注册表比较,覆盖了从纯文本到二进制文件的广泛使用场景。 对于文本文件的比较,Beyond Compare提供了语法高亮行号等辅助功能,让用户在审查代码或文档时能更快地定位差异点。表格比较功能则特别适用于数据分析处理任务,可以快速识别两个Excel电子表格之间的不同之处。在进行图片文件的比较时,用户可以通过直观的视图了解图片之间的微小差别,这在图像处理质量控制中尤其有用。 此外,16进制比较功能为开发者提供了深入分析二进制文件差异的手段,无论是在软件开发还是在数据恢复方面都大有裨益。注册表比较则专注于Windows系统的核心配置文件,帮助IT专业人员快速定位系统配置的变化,这对于系统维护故障排除尤其重要。 Beyond Compare内置的文件浏览器允许用户在一个界面内完成文件的浏览、比较同步操作,极大的提高了工作效率。内置的差异调整合并修改功能让同步文件夹的工作更加精确便捷。用户可以针对不同的文件文件夹进行个性化设置,实现定制化的比较同步策略。
内容概要:本文介绍了一种基于Simulink的发电机故障暂态仿真模型,旨在深入研究发电机在发生各类短路故障(如单相接地、两相短路接地及两相相间短路)时电压与电流的动态变化特性。该模型精确构建了发电机及其保护系统的电气结构,能够有效模拟故障瞬间的暂态响应过程,全面分析不同接地方式(中性点不接地、经小电阻接地、经消弧线圈接地)对系统电气量的影响。通过仿真获取的电压、电流波形数据,可用于评估电力系统的暂态稳定性、验证继电保护装置的动作逻辑与灵敏性,并为系统控制策略优化及故障诊断提供理论支撑技术依据。; 适合人群:电气工程及其自动化、电力系统及其相关专业的高校本科生、研究生、科研人员,以及从事电力系统仿真分析、继电保护设计、电网运行维护等工作的工程技术人员。; 使用场景及目标:①用于高校教学与科学研究中对发电机故障机理及暂态过程的可视化分析与深入探讨;②支撑电力系统安全稳定分析、保护定值整定计算、控制策略优化与应急预案制定;③为实际电网故障后的诊断溯源、事故回溯与应急处置决策提供可靠的仿真平台与理论指导。; 阅读建议:建议读者结合MATLAB/Simulink仿真环境进行实践操作,按照文档指导逐步搭建仿真模型,设置不同类型的故障条件进行对比实验,重点观察并分析电压、电流波形的幅值、相位及衰减特性,深入理解其物理成因与系统影响,有条件者可进一步将模型扩展至多机系统以提升研究的工程应用价值。
源码下载地址: https://pan.quark.cn/s/a4b39357ea24 在信息技术行业,特别是智能手机维修改进的范畴内,“高通9008免拆机救黑砖教程工具”被视为一种通用的处理手段,它主要服务于那些面对设备无法正常运作或处于“黑砖”状态的消费者。这个压缩文件内含针对搭载高通处理器的智能手机的救援指南与实用工具,其核心目标在于协助用户在不进行物理拆解的前提下,成功进入9008模式,进而完成对手机的修复。 我们必须明确理解“高通9008模式”的概念。9008代表了高通芯片的一种下载状态,也称作EDL(eMMC Download Mode)。在该状态下,用户或技术人员能够直接对手机的存储单元进行编程操作、系统升级或固件回载,以此应对软件层面的故障。此类模式一般应用于手机无法正常启动或遭遇严重故障的场合,属于一种较为根本性的修复措施。 “黑砖”状态描述了手机因软件层面的异常而无法开机或完全失去反应的情况,其成因通常涉及系统崩溃、刷机失败、恶意软件入侵等。当常规的恢复措施如强制重启、恢复界面等手段均告无效时,就需要借助9008模式这类特殊通道来实施修复。 小米品牌手机广泛采用了高通处理器,因此当其产品遭遇黑砖问题时,该教程工具显示出极大的实用价值。此压缩文件可能包含以下组成部分: 1. **救砖教程**:提供详尽的流程说明,引导用户如何安全地将设备导入9008模式,以及如何运用相关工具执行固件恢复或刷新操作。 2. **驱动程序**:高通9008模式的有效运行依赖于特定的驱动程序以实现与电脑的通信,压缩包中或许就整合了这些驱动,用户需先行安装它们以便连接手机并开展修复工作。 3. **线刷工具**:诸如MiFlash、QFIL等工具,它们能够支持用户通过...
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值