KnowledgeInterfaces Interface CATICkeSignature

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


interface CATICkeSignature

Interface dedicated to signature management.
Role: A signature is a definition of the arguments of a Knowledge function or Knowledge expression.
for example : "name [arg: mode Type] : mode Type" ie: "Real sin (x: in int): out Real".
Such a signature is used to check the types compatibility when writing a relation
Example : cos(sin(tan(c)*2))
If you want to create a new Knowledge function usable in formulas/checks/programs, you'll have
to define a signature and an evaluator
This interface is mono implemented.

See also:
, ,


Method Index


o AddArgument(CATICkeArg_var)
Add an argument to the list.
o GetAllowedEditionContext()
indicates if this signature is to be seen in different editors.
o GetHTMLDescription()
Returns the function long HTML description given by either
o GetInformation()
Returns the information of a signature.
o GetLibraryIfReusable()
For a reusable function, this method returns the library name as used in the include statement
o GetPlainDescription()
Returns the function plain text description
o HasVariableArgNb()
Indicates if the number of argument is variable.
o IsUserVisible()
Indicates if the function is visible.
o Name()
Returns the name of the signature.
o Notation()
Returns signatures notation.
o Prototype()
Returns the list of arguments of this signature.
o PrototypeSize()
Returns the number of arguments of this signature.
o RankOfOptionalArguments()
Indicates if the signature has optional arguments and starting from which argument (rank 1 to N).
o Rename(CATUnicodeString&)
Renames the signature.
o ReturnedArg()
Returns the returned argument of the signature.
o SetAllowedEditionContext(short)
indicates if this signature is to be seen in different editors.
o SetFunctionQuality(short)
another way to define where this function is accessible, is to describe what it can and cannot support.
o SetInformation(CATCkeSignatureInfo)
Modifies the information that explains if a function is time consuming.
o SetLibraryForReusable(CATUnicodeString&)
Sets the Library name from which the function comes (only for reusable functions in edition context of a rule)
o SetNotation(CATICkeSignature::Mode)
Sets notation of the signature.
o SetPrototype(CATCkeListOfArg)
Modifies the whole list of arguments.
o SetRankOfOptionalArguments(int)
Defines if the signature has optional arguments and starting from which argument (rank 1 to N).
o SetReturnedArg(CATICkeArg_var&)
Sets the returned argument.
o SetUserVisibility(CATCke::Boolean&)
Modifies the visibility of the function.
o SetVariableArgNb(CATCke::Boolean&)
Modifies the variable number of arguments property.
o Show()
Shows the signature to the user.

Enumerated Type Index


o Mode
Signature mode: indicates how this function will be written in Knowledgeware language.

Methods


o AddArgument
public virtual AddArgument( const iArgToAdd)
Add an argument to the list.
Parameters:
iArgToAdd
argument to be added
o GetAllowedEditionContext
public virtual GetAllowedEditionContext()
indicates if this signature is to be seen in different editors.
Returns:
the context of edition (formula = 1, rule = 2, check = 4, set of equations = 8, law = 16, actions = 32, expert check = 64, expert rule = 128)
o GetHTMLDescription
public virtual GetHTMLDescription()
Returns the function long HTML description given by either
Returns:
a HTML description for the function
o GetInformation
public virtual GetInformation()
Returns the information of a signature. Not supposed to be used by anybody else than the Knowledge editors.
Returns:
the information.
o GetLibraryIfReusable
public virtual GetLibraryIfReusable()
For a reusable function, this method returns the library name as used in the include statement
o GetPlainDescription
public virtual GetPlainDescription()
Returns the function plain text description
Returns:
a plain text description for the function
o HasVariableArgNb
public virtual HasVariableArgNb()
Indicates if the number of argument is variable.
those signature must have at least one argument that defines the type of variable arguments.
Returns:

Legal values: CATCke::True if it has a variable number of arguments. CATCke::False if it has a constant number of arguments (default value).
o IsUserVisible
public virtual IsUserVisible()
Indicates if the function is visible.
A function is by default visible.
If it is invisible, it is never shown in the V5 editors.
Returns:

Legal values: CATCke::True if it is visible. CATCke::False if not.
o Name
public virtual Name()
Returns the name of the signature.
(example : "sin")
o Notation
public virtual Notation()
Returns signatures notation.
Indicates if it is an operator, a function, a method or something else
Returns:

Legal values: the notation can be Function to be seen as a function : f(x,y), or Method to be seen as a method : x,f(y), or Operator do not use, or Special do not use, or Attribut to be seen as an attribute : x.f.
o Prototype
public virtual Prototype()
Returns the list of arguments of this signature.
Returns:
list of arguments (not to be deallocated)
o PrototypeSize
public virtual PrototypeSize()
Returns the number of arguments of this signature.
(Can be 0).
Returns:
the number of arguments.
o RankOfOptionalArguments
public virtual RankOfOptionalArguments()
Indicates if the signature has optional arguments and starting from which argument (rank 1 to N).
Returns:
0 to declare that there is no optional argument (by default). 1 to N .
o Rename
public virtual Rename( const iNewName)
Renames the signature.
Parameters:
iNewName
New name Note that this method is supposed to be used only at the definition stage of a signature. It is not supposed to be modified afterwards on existing signatures.
o ReturnedArg
public virtual ReturnedArg()
Returns the returned argument of the signature.
o SetAllowedEditionContext
public virtual SetAllowedEditionContext( context)
indicates if this signature is to be seen in different editors. By default, a function can be seen in any editor of Knowledge Advisor and Knowledge Expert, except set of equations.
Parameters:
context
context of edition (formula = 1, rule = 2, check = 4, set of equations = 8, law = 16, actions = 32, expert check = 64, expert rule = 128) Note that this method is supposed to be used only at the definition stage of a signature. It is not supposed to be modified afterwards on existing signatures.
o SetFunctionQuality
public virtual SetFunctionQuality( Quality)
another way to define where this function is accessible, is to describe what it can and cannot support.
Parameters:
Quality
the quality of the function By default, a function can be seen in any editor of Knowledge Advisor and Knowledge Expert, except set of equations. (inversible = 1, create object = 2, operate treatment = 4, is not update compliant = 8) Note that this method is supposed to be used only at the definition stage of a signature. It is not supposed to be modified afterwards on existing signatures.
o SetInformation
public virtual SetInformation( const info)
Modifies the information that explains if a function is time consuming.
Parameters:
info
information Note that this method is supposed to be used only at the definition stage of a signature. It is not supposed to be modified afterwards on existing signatures.
o SetLibraryForReusable
public virtual SetLibraryForReusable( const iLibName)
Sets the Library name from which the function comes (only for reusable functions in edition context of a rule)
Parameters:
iLibName
The library name as used in the Include statement
o SetNotation
public virtual SetNotation( iNotation)
Sets notation of the signature. Function is default value.
Parameters:
iNotation
notation to be set.
Legal values: the notation can be Function to be seen as a function : f(x,y), or Method to be seen as a method : x,f(y), or Operator do not use, or Special do not use, or Attribut to be seen as an attribute : x.f. Note that this method is supposed to be used only at the definition stage of a signature. It is not supposed to be modified afterwards on existing signatures.
o SetPrototype
public virtual SetPrototype( const iListOfArguments)
Modifies the whole list of arguments.
Parameters:
iListOfArguments
list of arguments to replace Note that this method is supposed to be used only at the definition stage of a signature. It is not supposed to be modified afterwards on existing signatures.
o SetRankOfOptionalArguments
public virtual SetRankOfOptionalArguments( const iRankForOptionalArguments)
Defines if the signature has optional arguments and starting from which argument (rank 1 to N).
Parameters:
iRankForOptionalArguments
0 to declare that there is no optional argument (by default). 1 to N .
o SetReturnedArg
public virtual SetReturnedArg( const iReturnedArg)
Sets the returned argument.
Parameters:
iReturnedArg
returned arg Note that this method is supposed to be used only at the definition stage of a signature. It is not supposed to be modified afterwards on existing signatures.
o SetUserVisibility
public virtual SetUserVisibility( const iVariable)
Modifies the visibility of the function.
A function is by default visible.
If it is invisible, it is never shown in the V5 editors.
Parameters:
iVariable

Legal values: CATCke::True if it should be visible. CATCke::False if not.
o SetVariableArgNb
public virtual SetVariableArgNb( const iVariable)
Modifies the variable number of arguments property.
Parameters:
iVariable

Legal values: CATCke::True if it has a variable number of arguments. CATCke::False if it has a constant number of arguments (default value). Note that this method is supposed to be used only at the definition stage of a signature. It is not supposed to be modified afterwards on existing signatures.
o Show
public virtual Show()
Shows the signature to the user.
Example: "sin(Real) : Real" This method is the one used in Knowledge wizard.
Returns:
string used to show the signature to the user

Enumerated Types


o Mode
enum Mode {
  Function,
  Method,
  Operator,
  Special,
  Attribute,
  Event
}
Signature mode: indicates how this function will be written in Knowledgeware language.
Legal values: the notation can be Function to be seen as a function : f(x,y), or Method to be seen as a method : x,f(y), or Operator do not use, or Special do not use, or Attribut to be seen as an attribute : x.f.

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

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