|
JavaTM 2 Platform Standard Ed. 5.0 |
|||||||||
ÀÌÀü Ŭ·¡½º ´ÙÀ½ Ŭ·¡½º | ÇÁ·¹ÀÓÀ¸·Î ÇÁ·¹ÀÓ ¾øÀÌ | |||||||||
°³¿ä: NESTED | Çʵå | constructor | ¸Þ¼µå | »ó¼¼: Çʵå | »ý¼ºÀÚ | ¸Þ¼µå |
java.lang.Objectjava.beans.Statement
java.beans.Expression
public class Expression
Expression
°´Ã¼´Â
Ÿ°Ù°ú º¹¼öÀÇ Àμö¿¡ ´ÜÀÏÀÇ ¸Þ¼µå¸¦ Àû¿ëÇÏ´Â °ÍÀ¸·Î½á, ´ÜÀÏÀÇ ¹Ýȯ°ª ("a.getFoo()"
ÀÎ °æ¿ì¿Í °°ÀÌ)¸¦ ¾òÀ» ¼ö ÀÖ´Â ¿ø½ÃÀû½ÄÀÔ´Ï´Ù.
Expression
°´Ã¼´Â
½´ÆÛ Ŭ·¡½ºÀÇ ÇÁ·ÎÆÛƼ »Ó¸¸ÀÌ ¾Æ´Ï¶ó, °ª (ÀÌ ½ÄÀÇ Æò°¡½Ã¿¡ ¸®ÅϵÈ
°´Ã¼)µµ Á¦°øÇÕ´Ï´Ù. º¸Åë, ÀÌ ¹Ýȯ°ªÀº È£ÃâÇØ ¿øÀ¸·ÎºÎÅÍ Á¦°øµÇ´Â °ÍÀÌ ¾Æ´Ï¶ó, óÀ½À¸·Î getValue
¸¦ È£ÃâÇÒ ¶§, ¸Þ¼µå¸¦ µ¿ÀûÀ¸·Î °Ë»öÇØ, È£ÃâÇÏ´Â °Í¿¡ ÀÇÇØ °è»êµË´Ï´Ù.
getValue()
,
setValue(java.lang.Object)
»ý¼ºÀÚ °³¿ä | |
---|---|
Expression (Object value,
Object target,
String methodName,
Object [] arguments)
´ÜÀÏÀÇ °á°ú¸¦ µ¹·ÁÁÖ´Â ¸Þ¼µåÀÇ »õ·Î¿î Expression °´Ã¼¸¦ ÀÛ¼ºÇÕ´Ï´Ù. |
|
Expression (Object target,
String methodName,
Object [] arguments)
ÆÄ¶ó¹ÌÅÍÀÇ ÁöÁ¤¿¡ µû¶ó, target , methodName ¹× arguments ¸¦ °¡Áö´Â »õ·Î¿î Statement °´Ã¼¸¦ ÀÛ¼ºÇÕ´Ï´Ù. |
¸Þ¼µå °³¿ä | |
---|---|
Object |
getValue ()
ÀÌ ÀνºÅϽºÀÇ value ÇÁ·ÎÆÛƼ°¡ ¾ÆÁ÷ ¼³Á¤µÇ¾î ÀÖÁö ¾ÊÀº °æ¿ì, ÀÌ ¸Þ¼µå´Â Àμö¸¦ »ç¿ëÇØ, Ÿ°Ù»óÀÇ ÁöÁ¤µÈ methodName ·ÎºÎÅÍ ¸Þ¼µå¸¦ µ¿ÀûÀ¸·Î °Ë»öÇØ, È£ÃâÇÕ´Ï´Ù. |
void |
setValue (Object value)
ÀÌ ½ÄÀÇ °ªÀ» value ·Î
ÇÕ´Ï´Ù. |
String |
toString ()
Java ½ºÅ¸ÀÏÀÇ ±¸¹®À» »ç¿ëÇØ, ÀÌ ½ÄÀÇ °ªÀ» Ãâ·ÂÇÕ´Ï´Ù. |
Ŭ·¡½º java.beans. Statement ·ÎºÎÅÍ »ó¼ÓµÈ ¸Þ¼µå |
---|
execute,
getArguments,
getMethodName,
getTarget |
Ŭ·¡½º java.lang. Object ·ÎºÎÅÍ »ó¼ÓµÈ ¸Þ¼µå |
---|
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
»ý¼ºÀÚ »ó¼¼ |
---|
public Expression(Object target, String methodName, Object [] arguments)
target
, methodName
¹× arguments
¸¦ °¡Áö´Â »õ·Î¿î Statement
°´Ã¼¸¦ ÀÛ¼ºÇÕ´Ï´Ù.
target
- ÀÌ ½ÄÀÇ Å¸°ÙmethodName
- ÀÌ ½ÄÀÇ methodNamearguments
- ÀÌ ½ÄÀÇ Àμö. null
ÀÎ °æ¿ì, ºñ¾îÀÖ´Â ¹è¿ÀÌ »ç¿ëµÇ´ÂgetValue()
public Expression(Object value, Object target, String methodName, Object [] arguments)
Expression
°´Ã¼¸¦ ÀÛ¼ºÇÕ´Ï´Ù. ´Ù¸¸, ±× °á°ú°¡ °è»êµÉ °ÍÀº ¾ø½À´Ï´Ù. À̰ÍÀº ÀÌ »ý¼ºÀÚ°¡setValue
¸Þ¼µåÀÇ È£Ãâ¿¡ ÀÇÇØ value
ÆÄ¶ó¹ÌÅ͸¦ »ç¿ëÇØ value ÇÁ·ÎÆÛƼ¸¦ ¼³Á¤Çϱ⠶§¹®ÀÔ´Ï´Ù.
value
- ÀÌ ½ÄÀÇ °ªtarget
- ÀÌ ½ÄÀÇ Å¸°ÙmethodName
- ÀÌ ½ÄÀÇ methodNamearguments
- ÀÌ ½ÄÀÇ Àμö. null
ÀÎ °æ¿ì, ºñ¾îÀÖ´Â ¹è¿ÀÌ »ç¿ëµÇ´ÂsetValue(java.lang.Object)
¸Þ¼µåÀÇ »ó¼¼ |
---|
public Object getValue() throws Exception
getValue
°á°ú·Î¼ ¸®Åϵ˴ϴÙ
. value ÇÁ·ÎÆÛƼ°¡ ¼³Á¤µÇ¾î ÀÖ´Â °æ¿ì´Â setValue
È£ÃâÀΰ¡ ÀÌÀüÀÇ getValue
È£Ãâ¿¡ÀÇÇØ value ÇÁ·ÎÆÛƼ°¡ ¸®Åϵ˴ϴÙ
. ÀÌ °æ¿ì
¸Þ¼µåÀÇ °Ë»öÀ̳ª È£ÃâÀº ºÒÇÊ¿äÇÕ´Ï´Ù.
µðÆúÆ®¿¡¼´Â Expression
value ÇÁ·ÎÆÛƼ´Â ºñ°ø°³ÀÇ ÀÏÀÇÀÇ °ª (null
ÀÌ¿Ü)ÀÌ µÇ¾î, ¸Þ¼µå°¡ ¾ÆÁ÷ ºÒ·Á°¡
Áö ¾ÊÀº °ÍÀ» ³»ºÎÀûÀ¸·Î ³ªÅ¸³À´Ï´Ù. ¹Ýȯ°ª null
˼
±× ¿ÜÀÇ °ª°ú °°°Ô ÀÌ ±âº»°ªÀ» ¿Å°Ü³õ½À´Ï´Ù. ÀÌ ¶§¹®¿¡
½ÄÀÇ Æò°¡ ȸ¼ö´Â ¹Ýµå½Ã 1ȸ°¡ µË´Ï´Ù.
µ¿ÀûÀΠŸ°Ù ¹× Àμö¿¡
ÇÑ ¸Þ¼µåÀÇ ¼±Åà ¹æ¹ýÀÇ »ó¼¼ÇÑ °Í¿¡ ´ëÇÏ¿©´Â excecute
¸Þ¼µå¸¦ ÂüÁ¶ÇϽʽÿÀ.
Exception
Statement.execute()
,
setValue(java.lang.Object)
public void setValue(Object value)
value
·Î
ÇÕ´Ï´Ù. ÀÌ °ªÀº getValue ¸Þ¼µå·ÎºÎÅÍ ¸®Åϵ˴ϴÙ
. ÀÌ ¶§, ÀÌ ½Ä¿¡ °ü·ÃµÈ
¸Þ¼µå°¡ ºÒ·Á °¥ °ÍÀº ¾ø½À´Ï´Ù.
value
- ÀÌ ½ÄÀÇ °ªgetValue()
public String toString()
Statement
³»ÀÇ toString
|
JavaTM 2 Platform Standard Ed. 5.0 |
|||||||||
ÀÌÀü Ŭ·¡½º ´ÙÀ½ Ŭ·¡½º | ÇÁ·¹ÀÓÀ¸·Î ÇÁ·¹ÀÓ ¾øÀÌ | |||||||||
°³¿ä: NESTED | Çʵå | constructor | ¸Þ¼µå | »ó¼¼: Çʵå | »ý¼ºÀÚ | ¸Þ¼µå |
Copyright 2004 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms . Documentation Redistribution Policy µµ ÂüÁ¶ÇϽʽÿÀ.