Open topic with navigation

TIBCO® Enterprise Administrator 2.4.2

# Modeling State in Interface Style

To model a managed object that has states, implement the supplemental interface com.tibco.tea.agent.api.WithStatus. WithStatus requires that you implement one method, getStatus, which returns the current state of a managed object.

See also States Aspect.

Before you beginThe object is defined in interface style.

Procedure Implement the WithStatus interface in your managed object type.
The status method must return an instance of the class com.tibco.tea.agent.types.AgentObjectStatus. AgentObjectStatus is a standard format for encapsulating state within agents. It has three fields:
state
Required. The state name.
desc
Optional. An interpretive description of the state.
uptime
Optional. The length of time that the managed object has been in this state.

    public class TomcatServer implements TeaObject, WithStatus
        ...
        public AgentObjectStatus getStatus() {
            ...
        }
    }

Did you find this helpful?

Yes No
Great!
Thanks for taking the time to give us some feedback.
Sorry about that

Why wasn't this helpful? (check all that apply)

Could not find what I was looking for
Instructions confusing or unclear
Instructions did not work

Want to tell us more?

Please select at least one option or provide details about the issue!!

Error occurred while submitting feedback.

Error2 occurred while submitting feedback.

TIBCO® Enterprise Administrator

Copyright © 1996-2025. Cloud Software Group, Inc. All Rights Reserved.