找回密码 注册 QQ登录
一站式解决方案

iCAx开思网

CAD/CAM/CAE/设计/模具 高清视频【积分说明】如何快速获得积分?快速3D打印 手板模型CNC加工服务在线3D打印服务,上传模型,自动报价
查看: 17563|回复: 4
打印 上一主题 下一主题

CAA: 怎样对catia自己的feature添加extension?

[复制链接]
跳转到指定楼层
1
发表于 2007-3-30 15:35:09 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式

马上注册,结交更多同行朋友,交流,分享,学习。

您需要 登录 才可以下载或查看,没有帐号?注册

x
各位高手:
        最近看了use case里面讲feature extension时候提到了给用户自定feature 添加extension,现在我想给已有feature添加extension,请问应该怎么做?
分享到:  QQ好友和群QQ好友和群 QQ空间QQ空间 腾讯微博腾讯微博 腾讯朋友腾讯朋友
收藏收藏 分享淘帖 赞一下!赞一下!
2
发表于 2007-3-30 17:09:21 | 只看该作者
CATIOsmExtendable::AddExtension()
3
发表于 2007-3-30 17:27:32 | 只看该作者
acoka兄,找遍了help viewer以及头文件,没发现CATIOsmExtendable呢。我用的是r14。
4
发表于 2007-4-2 09:10:58 | 只看该作者
哦,R17开始只能用Osm了
R16之前可以用

ObjectSpecsModeler Interface CATIExtendable
System.IUnknown
  |
  +--System.IDispatch
    |
    +--System.CATBaseUnknown
      |
      +--CATIExtendable

Usage: an implementation of this interface is supplied and you must use it as is. You should not reimplement it.


--------------------------------------------------------------------------------

interface CATIExtendable




Deprecated:
V5R15 CATIOsmExtendable Interface dedicated to the extension of spec objects.


--------------------------------------------------------------------------------

Method Index


o ActivateExtension(char*,char*,CATBoolean)
o DeactivateExtension(char*,char*,CATBoolean)
o IsExtensionActive(char*,char*)
o QueryAllExtensions(IID&,CATListPtrCATBaseUnknown**,char*)
o ReactivateExtension(char*,char*)
Methods


o ActivateExtension
public virtual HRESULT ActivateExtension( const char*  iExtensionName,
const char*  iApplicationId,
CATBoolean  iCreateIfNecessary =FALSE )=0  

Deprecated:
V5R15 CATIOsmExtendable#AddExtension Activates the extension.Role: an extension can be activated without necessarily actually existing in the applicative container. When using CATIOsmExtendable interface, activated/deactivated state is deprecated, extensions are seen as always active, so CATIOsmExtendable#AddExtension should be called only at creation of the extension on the base feature.
Parameters:
iExtensionName
the name of the extension to be activated
iApplicationId
the applicative container containing the extension to be activated
iCreateIfNecessary
TRUE - the extension is instantiated in the applicative container if it does not already exist
FALSE - the extension is not instantiated in the applicative container even if it does not already exist
Returns:
S_OK if succeeded
S_FALSE if creation requested but not needed
o DeactivateExtension
public virtual HRESULT DeactivateExtension( const char*  iExtensionName,
const char*  iApplicationId,
CATBoolean  iDestroyIfNecessary =FALSE)=0  

Deprecated:
V5R15 CATIOsmExtendable#RemoveExtension Deactivates the extension. Role: an extension can be deactivated without necessarily actually being removed from the applicative container. When using CATIOsmExtendable interface, activated/deactivated state is deprecated, extensions are seen as always active, so this method has its equivalent RemoveExtension on CATIOsmExtendable only if it is used with iDestroyIfNecessary=TRUE, else it is useless.
Parameters:
extensionName
the name of the extension to be deactivated
iApplicationId
the name of the applicative container containing the extension to be deactivated
iDestroyIfNecessary
TRUE = if the extension exists, it is removed
FALSE = even if the extension exists, it is not removed
o IsExtensionActive
public virtual HRESULT IsExtensionActive( const char*  iExtensionName,
const char*  iApplicationId =NULL )=0  

Deprecated:
V5R15 NoReplacement Tests if the extension is active, not active or does not exist at all. When using CATIOsmExtendable interface, activated/deactivated state is deprecated, extensions are seen as always active, so this method has no equivalent on CATIOsmExtendable.
Parameters:
iExtensionName
the name of the extension
iApplicationId
the name of the applicative container
Returns:
S_OK if the extension is active
S_FALSE if the extension exists but is inactive
E_FAIL if the extension does not exist at all
o QueryAllExtensions
public virtual HRESULT QueryAllExtensions( const IID&  iIID,
CATListPtrCATBaseUnknown**  oLst,
const char*  iApplicationId =NULL )= 0  

Deprecated:
V5R15 CATIOsmExtendable#QueryAllExtensions Returns all the active extensions implementing the requested interface in the requested applicative container.
Parameters:
IID
the requested interface
oLst
the list of all the active extensions implementing the requested interface in the requested applicative container, if any. The list is in activation reverse order (last activated first).
iApplicationId
the name of the applicative container. If NULL, returns all the active extensions, regardless of the applicative container.
o ReactivateExtension
public virtual HRESULT ReactivateExtension( const char*  iWeakType,
const char*  iApplicationId)=0  

Deprecated:
V5R15 NoReplacement Reactivates the extension.Role: An extension can be activated by invoking its supertype. When using CATIOsmExtendable interface, activated/deactivated state is deprecated, extensions are seen as always active, so this method has no equivalent on CATIOsmExtendable.
Parameters:
iWeakType
the type or supertype of the extension to be activated
iApplicationId
the applicative container containing the extension to be activated
Returns:
S_OK if succeeded


--------------------------------------------------------------------------------
This object is included in the file: CATIExtendable.h
If needed, your Imakefile.mk should include the module: CATObjectSpecsModeler
--------------------------------------------------------------------------------

Copyright © 2003, Dassault Systèmes. All rights reserved.
5
发表于 2007-4-2 11:12:22 | 只看该作者
CATIExtendable这个接口已经找到了,请问我应该怎样给catia已有的feature添加extension?和给自定义的feature添加方法一样吗?
您需要登录后才可以回帖 登录 | 注册

本版积分规则

3D打印手板模型快速制作服务,在线报价下单!

QQ 咨询|手机版|联系我们|iCAx开思网  

GMT+8, 2024-12-23 07:12 , Processed in 0.024599 second(s), 11 queries , Gzip On, Redis On.

Powered by Discuz! X3.3

© 2002-2024 www.iCAx.org

快速回复 返回顶部 返回列表