Package org.netxms.client.ai
Class AiQuestion
java.lang.Object
org.netxms.client.ai.AiQuestion
AI agent question for user interaction
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumConfirmation type for binary questions -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintGet chat ID this question belongs to.Get confirmation type for binary questions.Get additional context for the question (e.g., command to be approved).longgetId()Get question ID.Get negative button label based on confirmation type.Get options for multiple choice questions.Get positive button label based on confirmation type.getText()Get question text.intGet remaining timeout in seconds.booleanCheck if this is a multiple choice question.
-
Constructor Details
-
AiQuestion
Create question object from NXCP message.- Parameters:
msg- NXCP message
-
-
Method Details
-
getId
public long getId()Get question ID.- Returns:
- question ID
-
getChatId
public int getChatId()Get chat ID this question belongs to.- Returns:
- chat ID
-
isMultipleChoice
public boolean isMultipleChoice()Check if this is a multiple choice question.- Returns:
- true if multiple choice, false if binary confirmation
-
getConfirmationType
Get confirmation type for binary questions.- Returns:
- confirmation type
-
getPositiveLabel
Get positive button label based on confirmation type.- Returns:
- positive button label
-
getNegativeLabel
Get negative button label based on confirmation type.- Returns:
- negative button label
-
getText
Get question text.- Returns:
- question text
-
getContext
Get additional context for the question (e.g., command to be approved).- Returns:
- context string, may be empty
-
getOptions
Get options for multiple choice questions.- Returns:
- list of options, empty for binary questions
-
getTimeoutSeconds
public int getTimeoutSeconds()Get remaining timeout in seconds.- Returns:
- timeout in seconds
-