|
JavaTM 2 Platform Standard Ed. 5.0 |
|||||||||
ÀÌÀü Ŭ·¡½º ´ÙÀ½ Ŭ·¡½º | ÇÁ·¹ÀÓÀ¸·Î ÇÁ·¹ÀÓ ¾øÀÌ | |||||||||
°³¿ä: NESTED | Çʵå | »ý¼ºÀÚ | ¸Þ¼µå | »ó¼¼: Çʵå | »ý¼ºÀÚ | ¸Þ¼µå |
public interface ModelMBeanNotificationBroadcaster
ModelMBean´Â ÀÌ ÀÎÅÍÆäÀ̽º¸¦ ±¸ÇöÇÒ Çʿ䰡 ÀÖ½À´Ï´Ù. ÀÌ ÀÎÅÍÆäÀ̽ºÀÇ ±¸ÇöÀº ¸ðµç JMX ¿¡ÀÌÀüÆ®¿¡ ºÎ¼ÓµÇ¾î ÀÖ½À´Ï´Ù.
°ü¸® ´ë»óÀÌ µÇ´Â Java ÀÚ¿øÀº MBeanServer createMBean ¸Þ¼µå¸¦ »ç¿ëÇØ, ModelMBean¸¦ ÀνºÅϽºÈÇÕ´Ï´Ù. ´ÙÀ½¿¡ ModelMBean ÀνºÅϽºÀÇ ModelMBeanInfo (Descriptor ÷ºÎ)¸¦ ¼³Á¤ÇÕ´Ï´Ù. ModelMBean ModelMBeanInfo ¿¡¼ °ø°³µÈ ¼Ó¼º°ú ¿ÀÆÛ·¹À̼ǿ¡´Â MBean, Ä¿³ØÅÍ, ¾î´ðÅͷκÎÅÍ ¾×¼¼½º ÇÒ ¼ö ÀÖ½À´Ï´Ù. ModelMBeanInfo Descriptor¸¦ »ç¿ëÇØ, °ü¸® ´ë»ó ¾îÇø®ÄÉÀ̼dz»ÀÇ °ª°ú ¸Þ¼µå¸¦ Á¤ÀÇÇØ, ModelMBean ¼Ó¼º ¹× ¿ÀÆÛ·¹À̼ǿ¡ ¸Ê ÇÒ ¼ö ÀÖ½À´Ï´Ù . ÀÌ ¸ÅÇÎÀº XML Çü½ÄÀÇ ÆÄÀÏÀ» »ç¿ëÇÑ °³¹ß½Ã, ¶Ç´Â ½ÇÇà½Ã¿¡ ÇÁ·Î±×·¥À» »ç¿ëÇØ µ¿ÀûÀ¸·Î Á¤ÀÇÇÒ ¼ö ÀÖ½À´Ï´Ù.
MBeanServer ·Î ÀνºÅϽºÈ µÈ MBean´Â ¸ðµÎ °ü¸® ´ë»óÀÌ µË´Ï´Ù. ÀÌ·¯ÇÑ MBean ¼Ó¼º°ú ¿ÀÆÛ·¹À̼ǿ¡´Â MBeanServer¿¡ Á¢¼ÓµÈ Ä¿³ØÅÍ ¶Ç´Â ¾î´ðÅÍ °æÀ¯·Î ¿ø°Ý Á¢±Ù ÇÒ ¼ö ÀÖ½À´Ï´Ù. JMX ÁذÅÀÇ MBean°¡ ¾Æ´Ñ Java °´Ã¼´Â MBeanServer¿¡ µî·ÏÇÒ ¼ö ¾ø½À´Ï´Ù. ÀÚ¿øÀº ModelMBean¸¦ ÀνºÅϽºÈÇÏ´Â °ÍÀ¸·Î MBean À¯È¿¼ºÀ» º¸ÁõÇÕ´Ï´Ù.
¸ðµç public ¸Þ¼µå·Î MBeanException ¹× RuntimeOperationsException°¡ Throw µÉ Çʿ䰡 ÀÖ½À´Ï´Ù. ÀÌ·¸°Ô ÇÏ´Â °ÍÀ¸·Î ºÐ»êÇü Åë½Å (RMI, EJB µî)¿¡ ÇÑ ¿¹¿Ü¸¦ ·¦ ÇÒ ¼ö ÀÖ½À´Ï´Ù. »ç¾ç ¹× javadoc¿¡ ±âÀçµÇ¾î ÀÖ´Â ½Ã³ª¸®¿À À̿ܿ¡¼´Â ±¸ÇöÀÌ ¹Ýµå½Ã ÀÌ·¯ÇÑ ¿¹¿Ü¸¦ Throw ÇÑ´Ù°í´Â ÇÒ ¼ö ¾ø½À´Ï´Ù.
¸Þ¼µå °³¿ä | |
---|---|
void |
addAttributeChangeNotificationListener (NotificationListener listener,
String attributeName,
Object handback)
NotificationListener ÀÎÅÍÆäÀ̽º¸¦ ±¸ÇöÇÏ´Â °´Ã¼¸¦ ¸®½º³Ê·Î¼ µî·ÏÇÕ´Ï´Ù. |
void |
removeAttributeChangeNotificationListener (NotificationListener listener,
String attributeName)
RequiredModelMBean ·ÎºÎÅÍ attributeChangeNotification ¸®½º³Ê¸¦ »èÁ¦ÇÕ´Ï´Ù. |
void |
sendAttributeChangeNotification (Attribute oldValue,
Attribute newValue)
ModelMBean »óÀÇ µî·ÏÀÌ ³¡³ AttributeChangeNotification ¸®½º³Ê¿¡°Ô, ¼Ó¼ºÀÇ ³°Àº °ª°ú »õ·Î¿î °ªÀ» Æ÷ÇÔÇÑ attributeChangeNotification¸¦ ¼Û½ÅÇÕ´Ï´Ù. |
void |
sendAttributeChangeNotification (AttributeChangeNotification notification)
ModelMBean »óÀÇ µî·ÏÀÌ ³¡³ attributeChangeNotification ¿¡ °Ç³×¹Þ´Â attributeChangeNotification¸¦ ¼Û½ÅÇÕ´Ï´Ù. |
void |
sendNotification (Notification ntfyObj)
ModelMBean »óÀÇ µî·ÏÀÌ ³¡³ Notification ¸®½º³Ê¿¡°Ô, jmx.modelmbean.generic ÅëÁö·Î¼ °Ç³×¹Þ´Â Notification¸¦ ¼Û½ÅÇÕ´Ï´Ù. |
void |
sendNotification (String ntfyText)
ModelMBean »óÀÇ µî·ÏÀÌ ³¡³ Notification ¸®½º³Ê¿¡°Ô, °Ç³×¹Þ´Â ÅØ½ºÆ® ij¸¯ÅÍ ¶óÀÎÀ» Æ÷ÇÔÇÑ Notification¸¦ ¼Û½ÅÇÕ´Ï´Ù. |
ÀÎÅÍÆäÀ̽º javax.management. NotificationBroadcaster ·ÎºÎÅÍ »ó¼ÓµÈ ¸Þ¼µå |
---|
addNotificationListener,
getNotificationInfo,
removeNotificationListener |
¸Þ¼µåÀÇ »ó¼¼ |
---|
void sendNotification(Notification ntfyObj) throws MBeanException, RuntimeOperationsException
ntfyObj
- ¸®½º³Ê °´Ã¼ÀÇ handleNotification ¸Þ¼µå¿¡°Ô °Ç³×Áö´Â ÅëÁö
MBeanException
- ¹è°ªÀÌ ³¡³ Åë½Å ExceptionÀ»
·¦ ÇÑ´Ù
RuntimeOperationsException
- IllegalArgumentExceptionÀ»
·¦ ÇÑ´Ù. ÆÄ¶ó¹ÌÅͷμ °Ç³×¹ÞÀº Notification °´Ã¼°¡ nullÀÎ °æ¿ìvoid sendNotification(String ntfyText) throws MBeanException, RuntimeOperationsException
ntfyText
- Notification ·Î ÁöÁ¤µÇ¾î ¸®½º³Ê °´Ã¼ÀÇ handleNotification ¸Þ¼µå¿¡°Ô °Ç³×Áö´Â ÅØ½ºÆ®. ±¸Ãà ³¡³ Notification´Â type "jmx.modelmbean.generic" source this ModelMBean instance sequence 1
MBeanException
- ¹è°ªÀÌ ³¡³ Åë½Å ExceptionÀ»
·¦ ÇÑ´Ù
RuntimeOperationsException
- IllegalArgumentExceptionÀ»
·¦ ÇÑ´Ù. ÆÄ¶ó¹ÌÅͷμ °Ç³×¹ÞÀº Notification ÅØ½ºÆ® ij¸¯ÅÍ ¶óÀÎÀÌ nullÀÎ °æ¿ìvoid sendAttributeChangeNotification(AttributeChangeNotification notification) throws MBeanException, RuntimeOperationsException
notification
- ¸®½º³Ê °´Ã¼ÀÇ handleNotification ¸Þ¼µå¿¡°Ô °Ç³×Áö´Â ÅëÁö
MBeanException
- ¹è°ªÀÌ ³¡³ Åë½Å ExceptionÀ»
·¦ ÇÑ´Ù
RuntimeOperationsException
- IllegalArgumentExceptionÀ»
·¦ ÇÑ´Ù. ÆÄ¶ó¹ÌÅͷμ °Ç³×¹ÞÀº AttributeChangeNotification °´Ã¼°¡ nullÀÎ °æ¿ìvoid sendAttributeChangeNotification(Attribute oldValue, Attribute newValue) throws MBeanException, RuntimeOperationsException
oldValue
- Attribute
ÃʱⰪ
newValue
- Attribute
ÇöÀçÀÇ °ª
±¸Ãà ³¡³ attributeChangeNotification. type "jmx.attribute.change" source this ModelMBean instance sequence 1 attributeName oldValue.getName() attributeType oldValue's class attributeOldValue oldValue.getValue() attributeNewValue newValue.getValue()
MBeanException
- ¹è°ªÀÌ ³¡³ Åë½Å ExceptionÀ»
·¦ ÇÑ´Ù
RuntimeOperationsException
- IllegalArgumentExceptionÀ»
·¦ ÇÑ´Ù. ÆÄ¶ó¹ÌÅͷμ °Ç³×¹Þ´Â Attribute °´Ã¼°¡ null ÀÎ °æ¿ì, ¶Ç´Â ÆÄ¶ó¹ÌÅÍ¿¡ °°Àº À̸§ÀÇ Attribute °´Ã¼°¡ º¹¼ö ÁöÁ¤µÇ¾úÀ» °æ¿ìvoid addAttributeChangeNotificationListener(NotificationListener listener, String attributeName, Object handback) throws MBeanException, RuntimeOperationsException, IllegalArgumentException
listener
- µî·ÏÀÌ ³¡³ MBean°¡ ¹ßÇàÇÑ ÅëÁö¸¦ ó¸®ÇÏ´Â ¸®½º³Ê °´Ã¼attributeName
- ModelMBean ¼Ó¼ºÀÇ À̸§. ÀÌ ¼Ó¼ºÀÇ º¯°æ ÅëÁö¸¦ ¼ö½ÅÇÑ´Ù. nullÀÎ °æ¿ì, ¾î´À ¼Ó¼ºÀÌ º¯°æµÇ¾úÀ» ¶§µµ attributeChangeNotification°¡ ¹ßÇàµÇ´Âhandback
- ÅëÁö°¡ ¹ßÇàµÇ¾úÀ» ¶§ ÅëÁö¿Í ÇÔ²² ¸®½º³Ê¿¡°Ô ¼Û½ÅµÇ´Â ÄÁÅØ½ºÆ®
IllegalArgumentException
- ¸®½º³Ê´Â null ·Î ÇÒ ¼ö ¾ø´Ù
MBeanException
- ¹è°ªÀÌ ³¡³ Åë½Å ExceptionÀ»
·¦ ÇÑ´Ù
RuntimeOperationsException
- IllegalArgumentExceptionÀ»
·¦ ÇÑ´Ù. ÆÄ¶ó¹ÌÅͷμ °Ç³×¹Þ´Â ¼Ó¼º¸íÀÌ Á¸ÀçÇÏÁö ¾Ê´Â °æ¿ìremoveAttributeChangeNotificationListener(javax.management.NotificationListener, java.lang.String)
void removeAttributeChangeNotificationListener(NotificationListener listener, String attributeName) throws MBeanException, RuntimeOperationsException, ListenerNotFoundException
listener
- µî·ÏÀÌ ³¡³ MBean°¡ ¹ßÇàÇÑ ÅëÁö¸¦ ó¸®Çϰí ÀÖ´ø ¸®½º³ÊÀÇ À̸§. ÀÌ ¸Þ¼µå´Â ÀÌ ¸®½º³Ê¿¡ °üÇÑ ¸ðµç Á¤º¸¸¦ »èÁ¦ÇÏ´ÂattributeName
- ¼Ó¼º. ¸®½º³Ê´Â ÀÌ ¼Ó¼ºÀÇ attributeChangeNotification¸¦ ¼ö½ÅÇÒ Çʿ䰡 ¾ø¾îÁ³´Ù. nullÀÎ °æ¿ì, ¸ðµç attributeChangeNotification
¸®½º³Ê°¡ »èÁ¦µÈ´Ù
ListenerNotFoundException
- ¸®½º³Ê°¡ MBean¿¡ µî·ÏµÇÁö ¾ÊÀºÁö, nullÀÎ °æ¿ì
MBeanException
- ¹è°ªÀÌ ³¡³ Åë½Å ExceptionÀ»
·¦ ÇÑ´Ù
RuntimeOperationsException
- IllegalArgumentExceptionÀ»
·¦ ÇÑ´Ù. inAttributeName ÆÄ¶ó¹ÌÅͰ¡ ¼Ó¼º¸í¿¡ ÀÏÄ¡ÇÏÁö ¾Ê´Â °æ¿ìaddAttributeChangeNotificationListener(javax.management.NotificationListener, java.lang.String, java.lang.Object)
|
JavaTM 2 Platform Standard Ed. 5.0 |
|||||||||
ÀÌÀü Ŭ·¡½º ´ÙÀ½ Ŭ·¡½º | ÇÁ·¹ÀÓÀ¸·Î ÇÁ·¹ÀÓ ¾øÀÌ | |||||||||
°³¿ä: NESTED | Çʵå | »ý¼ºÀÚ | ¸Þ¼µå | »ó¼¼: Çʵå | »ý¼ºÀÚ | ¸Þ¼µå |
Copyright 2004 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms . Documentation Redistribution Policy µµ ÂüÁ¶ÇϽʽÿÀ.