Message Behaviour

MESSAGE

Variants:

1. MESSAGE xnnn.

2. MESSAGE ID id TYPE mtype NUMBER n.

3. MESSAGE xnnn(mid).

4. MESSAGE msg TYPE mtype.

Effect

Sends a message. Messages are stored in the table T100, are processed using transaction SE91 and can be created by forward navigation.

The ABAP runtime environment handles messages according to the type declared in the MESSAGE statement and the context in which the message was sent. The following message types exist:

A - Abend
: Transaction terminated
E - Error
: Error message
I - Info
: Information
S - Status
: Status message
W - Warning
: Correction possible
X - Exit
: Transaction terminated with short dump

Messages are mainly used to handle user input on screens. The following table shows the behavior of each message type in each context. An explanation of the numbers used is included at the end of the table:

                            A     E     I     S     W     X
--------------------------------------------------------------
PAI Module                   1     2     3     4     5     6
PAI Module for POH            1     7     3     4     7

    6
PAI Module for POV            1     7     3     4     7

    6
--------------------------------------------------------------
AT SELECTION-SCREEN ...     1     8     3     4     9     6
AT SELECTION-SCREEN for  POH  1     7     3     4     7     6
AT SELECTION-SCREEN for  POV  1     7     3     4     7     6
AT SELECTION-SCREEN ON EXIT 1     7     3     4     7     6
--------------------------------------------------------------
AT LINE-SELECTION           1    10     3     4    10     6
AT PFn                      1    10     3     4    10     6
AT USER-COMMAND             1    10     3     4    10     6
--------------------------------------------------------------
INITIALIZATION              1    11     3     4    11     6
START-OF-SELECTION          1    11     3     4    11     6
GET                         1    11     3     4    11     6
END-OF-SELECTION            1    11     3     4    11     6
--------------------------------------------------------------
TOP-OF-PAGE                 1    11     3     4    11     6
END-OF-PAGE                 1    11     3     4    11     6
TOP-OF-PAGE DURING ...      1    10     3     4    10     6
--------------------------------------------------------------
LOAD-OF-PROGRAM             1     1     4     4     4     6
--------------------------------------------------------------
PBO Module                   1     1     4     4     4     6
AT SELECTION-SCREEN OUTPUT  1     1     4     4     4     6
--------------------------------------------------------------
Procedure:                    see

Messages
--------------------------------------------------------------

  1. The message appears in a dialog box and the program terminates. When the user has confirmed the message, control returns to the next- highest area. All the internal sessions are deleted from the stack.

  2. The message appears in the status line. Then PAI terminates and the system returns to the current screen. All the screen fields combined using FIELD or CHAIN are now ready for input. The user must enter new values. The system triggers the PAI event again, with the new values.

  3. The message appears in a dialog box. Once the user has confirmed the message, the program continues immediately after the MESSAGE statement.

  4. The message appears in the status line of the next screen. The program continues immediately after the message statement.

  5. The message appears in the status line. Then the system continues as in 2, except that the user can quit the message using ENTER without having to enter new values. The system continues handling the PAI event from immediately after the message statement.

  6. No message is displayed and a runtime error, MESSAGE_TYPE_X, is triggered. The short dump text contains the message identification.

  7. The program terminates with a runtime error DYNPRO_MSG_IN_HELP. While F1 and F4 are processed, the system cannot send error messages or warnings.

  8. The message appears in the status line. Then the system stops selection screen processing and returns to the selection screen itself. The screen fields specified in the additions to the AT SELECTION-SCREEN statement are now ready for input. The user must enter new values. The system then starts processing the selection screen again with the new values.

  9. The message appears in the status line. Then the system continues as in 8, except the the user can quit the message using ENTER, without having to enter new values. The system continues handling the PAI event from immediately after the message statement.

  10. The message appears in the status line and the processing block terminates. The list level is displayed as before.

  11. The message appears in the status line and the processing block terminates. The system then returns to the program call.

  12. For a demonstration of messages in different contexts, see Example Programs for Messages.

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
### 回答1: 行为树(Behaviour Tree)是一种用于控制程序行为的树状结构。它是由人工智能和游戏开发领域的专家设计的一种算法,用来描述构成行为的复杂关系。 行为树由节点组成,每个节点代表一个行为或动作。节点可以是一些基本的行为,如移动、攻击、防御等,也可以是复合节点、条件节点和修饰节点等。 复合节点包括顺序节点、选择节点、并发节点、择优节点等,用于描述行为的执行逻辑和条件分支。条件节点描述达成某些条件的判断过程。修饰节点描述如何修改或增强一个行为的执行过程。 行为树是一种灵活、可扩展的算法,可以用于控制各种不同类型的程序行为,如游戏玩家的人工智能、机器人的自主控制、自动化运维等。它具有可视化、可调试、可维护的优点,能够帮助开发者快速构建出高质量的行为控制系统。 总之,行为树是一种强大的算法工具,它能够帮助开发者构建出高效、灵活、可维护的行为控制系统。 ### 回答2: 行为树(Behaviour Tree)是一种人工智能技术,通常用于控制电脑游戏角色的行为。它是一种树状结构,由一个根节点以及许多子节点组成。每个节点都代表一个行为或决策。行为树是一种可扩展的方式,可以轻松添加或删除节点。这使得它成为开发者在游戏中迅速实现AI控制的理想方案。 在行为树中,根节点的作用是选择适当的子节点进行执行。根据游戏中的情况,根节点将转换到不同的子节点。子节点包括基本行为节点(如移动、攻击、躲避),条件节点(如当玩家进入视野中),以及复合节点(如顺序节点、选择节点和并行节点)。复合节点可以将几个子节点合并为一个节点。 使用行为树制作游戏AI的重要好处是,它可以快速响应和动态更改。行为树的分层结构,使得AI角色能够智能地回应游戏环境的变化。此外,由于行为树结构简单,可视化编辑器的易用性也使得人类开发者轻松理解和编辑。 在游戏开发中,行为树是一种实用且普遍的AI实现方案。它的好处是它可以在不同的情况下快速响应变化,同时保持简单易用的编辑过程。但是,在设计过程中,需要开发者精心设计和实现AI的决策和行为方案。在行为树中添加节点需要进行有效的规划,以确保AI角色在游戏中表现得自然而又流畅。 ### 回答3: Behaviour Tree(行为树)是一种面向目标的编程模型,非常适合用于设计AI。它是由节点和连线组成的层级结构,从根节点开始,经过中间节点,最终达到叶子节点。通过控制节点的执行顺序和条件,可以有效地控制AI的行为。 Behaviour Tree的优点在于它的灵活性和可扩展性。节点可以根据需要自定义,从而适应各种需求。同时,行为树具有很好的可读性和可调试性,可以方便地追踪AI的状态和行为。 Behaviour Tree的使用范围广泛,可以用于设计各种AI,比如游戏角色、机器人、自动驾驶等。不同类型的AI可以使用不同的节点和条件,以满足不同的需求。 在实现中,Behaviour Tree通常使用面向对象的方式进行设计,其中各种节点和条件都是对象。AI通过不断调用节点和检查条件,实现了一系列复杂的行为,从而完成任务。 总的来说,Behaviour Tree是一种非常有效的AI设计模型,可以帮助开发者快速地设计和实现各种AI。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值