1 /*
2 * Licensed to the Apache Software Foundation (ASF) under one or more
3 * contributor license agreements. See the NOTICE file distributed with
4 * this work for additional information regarding copyright ownership.
5 * The ASF licenses this file to You under the Apache License, Version 2.0
6 * (the "License"); you may not use this file except in compliance with
7 * the License. You may obtain a copy of the License at
8 *
9 * http://www.apache.org/licenses/LICENSE-2.0
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
16 */
17 package org.apache.commons.el;
18
19 import java.beans.PropertyDescriptor;
20 import java.lang.reflect.Method;
21
22 /**
23 *
24 * <p>This contains the information for one property in a BeanInfo -
25 * PropertyDescriptor, read method, and write method. This class is
26 * necessary because the read/write methods in the PropertyDescriptor
27 * may not be accessible if the bean given to the introspector is not
28 * a public class. In this case, a publicly accessible version of the
29 * method must be found by searching for a public superclass/interface
30 * that declares the method (this searching is done by the
31 * BeanInfoManager).
32 *
33 * @author Nathan Abramson - Art Technology Group
34 * @version $Change: 181181 $$DateTime: 2001/06/26 09:55:09 $$Author: bayard $
35 **/
36
37 public class BeanInfoProperty
38 {
39 //-------------------------------------
40 // Properties
41 //-------------------------------------
42 // property readMethod
43
44 Method mReadMethod;
45 public Method getReadMethod ()
46 { return mReadMethod; }
47
48 //-------------------------------------
49 // property writeMethod
50
51 Method mWriteMethod;
52 public Method getWriteMethod ()
53 { return mWriteMethod; }
54
55 //-------------------------------------
56 // property propertyDescriptor
57
58 PropertyDescriptor mPropertyDescriptor;
59 public PropertyDescriptor getPropertyDescriptor ()
60 { return mPropertyDescriptor; }
61
62 //-------------------------------------
63 /**
64 *
65 * Constructor
66 **/
67 public BeanInfoProperty (Method pReadMethod,
68 Method pWriteMethod,
69 PropertyDescriptor pPropertyDescriptor)
70 {
71 mReadMethod = pReadMethod;
72 mWriteMethod = pWriteMethod;
73 mPropertyDescriptor = pPropertyDescriptor;
74 }
75
76 //-------------------------------------
77 }