Java Reference
In-Depth Information
Figure 4.1
The simplest case: direct implementation of an MBean interface.
The resulting management interface is the methods contained in
the PrinterMBean interface.
4.3.1
Direct implementation of an MBean interface
The first scenario deals with an MBean that manages a printer. The pattern is
described by figure 4.1, which shows the Printer class implementing the Printer-
MBean interface described earlier.
This is the simplest scenario: a Standard MBean is created by implementing
its own MBean interface. The management interface for the Printer class con-
tains the methods and attributes exposed in the interface PrinterMBean . In this
pattern, the PrinterMBean interface exposes only one attribute, PrintQuality (it is
write only).
4.3.2
Inheriting the management interface
Similar to the previous case, a valid MBean can be created by extending another
valid Standard MBean. Figure 4.2 depicts the CopierPrinter MBean.
Figure 4.2
Inheriting a management interface by
extending another Standard MBean.
The CopierPrinter MBean will have
a management interface identical to
that of the Printer MBean.
Search WWH ::




Custom Search