|
Java プラットフォーム 1.2 |
|||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | |||||||||
| 概要: 内部クラス | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | |||||||||
java.lang.Object
|
+--java.beans.FeatureDescriptor
|
+--java.beans.PropertyDescriptor
PropertyDescriptor は、アクセス用メソッドのペアを介して Java Bean が公開するプロパティを 1 つ記述します。
| コンストラクタの概要 | |
PropertyDescriptor(String propertyName,
Class beanClass)
getFoo および setFoo アクセス用メソッドを使って、標準の Java 規則に従うプロパティの PropertyDescriptor を構築します。 |
|
PropertyDescriptor(String propertyName,
Class beanClass,
String getterName,
String setterName)
単純なプロパティ名、およびプロパティの読み込み/書き込み用のメソッド名を引数に取ります。 |
|
PropertyDescriptor(String propertyName,
Method getter,
Method setter)
単純なプロパティ名、およびプロパティの読み込み/書き込み用の Method オブジェクトを引数に取ります。 |
|
| メソッドの概要 | |
Class |
getPropertyEditorClass()
このプロパティに対して登録されている明示的な PropertyEditor クラスを取得します。 |
Class |
getPropertyType()
プロパティの Class オブジェクトを取得します。 |
Method |
getReadMethod()
プロパティ値の読み込みに使うメソッドを取得します。 |
Method |
getWriteMethod()
プロパティ値の書き込みに使うメソッドを取得します。 |
boolean |
isBound()
「バウンド」プロパティを更新し、プロパティの変更時に PropertyChange イベントがトリガーされるようにします。 |
boolean |
isConstrained()
「制約」プロパティの更新を試み、プロパティの変更時に VetoableChange イベントがトリガーされるようにします。 |
void |
setBound(boolean bound)
「バウンド」プロパティを更新し、プロパティの変更時に PropertyChange イベントがトリガーされるようにします。 |
void |
setConstrained(boolean constrained)
「制約」プロパティの更新を試み、プロパティの変更時に VetoableChange イベントがトリガーされるようにします。 |
void |
setPropertyEditorClass(Class propertyEditorClass)
通常 PropertyEditor は、PropertyEditorManager を使って検索されます。 |
void |
setReadMethod(Method getter)
プロパティ値の読み込みに使うメソッドを設定します。 |
void |
setWriteMethod(Method setter)
プロパティ値の書き込みに使うメソッドを設定します。 |
| クラス java.beans.FeatureDescriptor から継承したメソッド |
attributeNames,
getDisplayName,
getName,
getShortDescription,
getValue,
isExpert,
isHidden,
isPreferred,
setDisplayName,
setExpert,
setHidden,
setName,
setPreferred,
setShortDescription,
setValue |
| クラス java.lang.Object から継承したメソッド |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
| コンストラクタの詳細 |
public PropertyDescriptor(String propertyName,
Class beanClass)
throws IntrospectionException
propertyName - プロパティのプログラム名beanClass - ターゲット bean の Class オブジェクト。たとえば、sun.beans.OurButton.class
public PropertyDescriptor(String propertyName,
Class beanClass,
String getterName,
String setterName)
throws IntrospectionException
propertyName - プロパティのプログラム名beanClass - ターゲット bean の Class オブジェクト。たとえば、sun.beans.OurButton.classgetterName - プロパティ値の読み取りに使うメソッド名。プロパティが書き込み専用の場合は nullsetterName - プロパティ値の書き込みに使うメソッド名。プロパティが読み込み専用の場合は null
public PropertyDescriptor(String propertyName,
Method getter,
Method setter)
throws IntrospectionException
propertyName - プロパティのプログラム名getter - プロパティ値の読み込みに使うメソッド。プロパティが書き込み専用の場合は nullsetter - プロパティ値の書き込みに使うメソッド。プロパティが読み込み専用の場合は null| メソッドの詳細 |
public Class getPropertyType()
ReadMethod が返す型
public Method getReadMethod()
public void setReadMethod(Method getter)
throws IntrospectionException
getter - 新しい読み込み用メソッドpublic Method getWriteMethod()
public void setWriteMethod(Method setter)
throws IntrospectionException
setter - 新しい書き込み用メソッドpublic boolean isBound()
public void setBound(boolean bound)
bound - これがバウンドプロパティの 場合は truepublic boolean isConstrained()
public void setConstrained(boolean constrained)
constrained - これが制約プロパティの場合は truepublic void setPropertyEditorClass(Class propertyEditorClass)
propertyEditorClass - PropertyEditor のクラスpublic Class getPropertyEditorClass()
|
Java プラットフォーム 1.2 |
|||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | |||||||||
| 概要: 内部クラス | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | |||||||||