Structure of a command

Definition of user’s Commands

A command, as called by the final user, is a classmethod that wraps the actual purpose of the command by a serie of generic tasks.

All user’s Commands are defined in code_aster.CodeCommands package and provided to the user as code_aster.Commands.

For the details about the execution of the commands see code_aster.Supervis.

Catalog description

Each command must define its user syntax through its catalog. The checking of the user keywords is performed by the Catalog objects (see SyntaxChecker).

See SyntaxObjects for the type of the values of the user’s keywords after the syntax checkings. For example, the value is always a list if max > 1. It is not necessary to check again in the implementation of the exec_() function of the command.

Utility functions for executors

operator — Generic operators

The function define_operators() automatically creates executors objects (ExecuteCommand or ExecuteMacro) for operators that are not already defined in the store, i.e. not already defined in the code_aster/Commands directory.

It is mainly a transtional feature that should make work most of the legacy commands with few changes.

code_aster.CodeCommands.operator.define_operators(store)[source]

Add definition of operators to the given store.

Parameters:

store (dict) – Store where the executors will be registered.