将Caché5的类导出成为Caché4的类的方法

Caché5的类较Caché4增加了一些新特性,所以要把Caché5的类导入到Caché4中需要注意以下的内容:

(以下内容来自Caché的帮助文件)

原文:
Exporting Class Definitions for Version 4.x
There are a number of new features in the version 5 object model that are not present in version 4. If you export a CDL file from version 5, by default it may not load on a version 4 system.
If you need to use classes defined on version 5 on version 4, use the $System.OBJ.ExportCDL method (see the %SYSTEM.OBJ class) from the Caché command line and specify a “4” option in the list of flags. If the “4” flag is present then the CDL will not contain any syntax incompatible with a version 4.x system.
Note:
ExportCDL adds comments to the exported CDL file if any incompatible features (such as PROCEDUREBLOCK/WEBMETHOD) are present in the exported classes. ExportCDL does not check for super classes or types not present on a 4.x system nor does it check for LANGUAGE values.

翻译:
导出类定义为Caché4.x版本
Caché5的对象模型增加了一些Caché4中没有的新特性,如果使用缺省设置导出Caché5的类,是不能被导入到Caché4中的。
如果需要在Caché4中使用由Caché5定义的类,在Terminal下使用$System.OBJ.ExportCDL命令(在$System.OBJ类中),并指定标志为4,导出的CDL文件会去除所有与Caché4不兼容的语法内容。
注意:
在上述导出的CDL文件中,ExportCDL命令会加上注释;ExportCDL命令不会检查在Caché4.x这没有的父类或者父类型,也不会检查LANGUAGE的值(这个不知道指的是什么)。
注释示例:
// WARNING! Cache Version 4 CDL doesn't support procedureblock. Please review

例子:w $System.OBJ.ExportCDL("FullClassName","d:/class.cdl","4")
(注意:在4中,必须把CDL文件放在数据库本地才能导入)

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值