View Javadoc

1   package cz.cuni.amis.pogamut.base3d.agent.jmx;
2   
3   import cz.cuni.amis.pogamut.base.agent.jmx.*;
4   import cz.cuni.amis.pogamut.base.agent.jmx.adapter.AgentMBeanAdapter;
5   import cz.cuni.amis.pogamut.base3d.agent.IAgent3D;
6   import cz.cuni.amis.pogamut.base3d.worldview.object.Location;
7   import cz.cuni.amis.pogamut.base3d.worldview.object.Rotation;
8   import cz.cuni.amis.pogamut.base3d.worldview.object.Velocity;
9   
10  import javax.management.InstanceAlreadyExistsException;
11  import javax.management.MBeanRegistrationException;
12  import javax.management.MBeanServer;
13  import javax.management.MalformedObjectNameException;
14  import javax.management.NotCompliantMBeanException;
15  import javax.management.ObjectName;
16  
17  /**
18   *
19   * @author ik
20   */
21  public class Agent3DMBeanAdapter<T extends IAgent3D> extends AgentMBeanAdapter<T> implements Agent3DMBeanAdapterMBean {
22  
23      public Agent3DMBeanAdapter(T agent, ObjectName objectName, MBeanServer mbs) throws MalformedObjectNameException, InstanceAlreadyExistsException, MBeanRegistrationException, NotCompliantMBeanException {
24          super(agent, objectName, mbs);
25      }
26  
27      @Override
28      public Location getLocation() {
29          return getAgent().getLocation();
30      }
31  
32      @Override
33      public Rotation getRotation() {
34          return getAgent().getRotation();
35      }
36  
37      @Override
38      public Velocity getVelocity() {
39          return getAgent().getVelocity();
40      }
41  
42  }