KnowledgeInterfaces Interface CATIAddLibrary

Usage: you can freely reimplement this interface.


interface CATIAddLibrary

Interface to implement to add Knowledge libraries.

Role: This interface helps us to find your specific Knowledge functions or Knowledge types that you would like to add to our language.

Usage:
If you want to customise the Knowledge tools (by adding functions, knowledge types ,etc...)

  • Implement this interface on one class that we call XX for example (that will also implement CATICreateInstance).
  • In the Add method create all the functions, , etc... and add them to CATITypeDictionary.
  • Create an Object Modeler dictionary (.dico file) explaining that XX implements CATICreateInstance and CATIAddLibrary in your shared library.


  • Those methods will be called by our product when necessary.

    For example, you may want to create a max(double,double) function that could then be used in formulas, checks or programs.

    The algorithm to find all functions is the following :
    We scan the Object Modeler Dictionnaries to find all objects implementing CATIAddLibrary and CATICreateInstance.
    For each object, we create it with CATICreateInstance, then get the CATIAddLibrary interface on it and call the Add Method.
    In the Add method, you can use the CreateFunction method.

    This interface is multi implemented by the different applications.
    The Add method is called only once. Thus, you don't need to verify that the types or functions that you're creating already exist.
    THIS INTERFACE MUST NOT BE USED BY APPLICATIONS TO LOAD THEIR LIBRARIES. USE CATITypeDictionary::LoadLibrary instead.
    THIS IS REALLY IMPORTANT BECAUSE A CACHE OPTIMIZATION IS PERFORMED IN LoadLibrary AND WE ENSURE THAT THIS METHOD CANNOT BE CALLED TWICE.
    See also:
    ,


    Method Index


    o Add()
    Add your own Knowledge functions or Knowledge types here.

    Methods


    o Add
    public virtual Add()
    Add your own Knowledge functions or Knowledge types here.

    This object is included in the file: CATIAddLibrary.h
    If needed, your Imakefile.mk should include the module: KnowledgeItf

    Copyright © 1999-2015, Dassault Systèmes. All rights reserved.