001/*
002 * Licensed to the Apache Software Foundation (ASF) under one or more
003 * contributor license agreements.  See the NOTICE file distributed with
004 * this work for additional information regarding copyright ownership.
005 * The ASF licenses this file to You under the Apache License, Version 2.0
006 * (the "License"); you may not use this file except in compliance with
007 * the License.  You may obtain a copy of the License at
008 *
009 *     http://www.apache.org/licenses/LICENSE-2.0
010 *
011 * Unless required by applicable law or agreed to in writing, software
012 * distributed under the License is distributed on an "AS IS" BASIS,
013 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
014 * See the License for the specific language governing permissions and
015 * limitations under the License.
016 */
017package org.apache.commons.el;
018
019import java.beans.IndexedPropertyDescriptor;
020import java.lang.reflect.Method;
021
022/**
023 *
024 * <p>This contains the information for one indexed property in a
025 * BeanInfo - IndexedPropertyDescriptor, read method, and write
026 * method.  This class is necessary because the read/write methods in
027 * the IndexedPropertyDescriptor may not be accessible if the bean
028 * given to the introspector is not a public class.  In this case, a
029 * publicly accessible version of the method must be found by
030 * searching for a public superclass/interface that declares the
031 * method (this searching is done by the BeanInfoManager).
032 * 
033 * @author Nathan Abramson - Art Technology Group
034 * @version $Change: 181181 $$DateTime: 2001/06/26 09:55:09 $$Author: bayard $
035 **/
036
037public class BeanInfoIndexedProperty
038{
039  //-------------------------------------
040  // Properties
041  //-------------------------------------
042  // property readMethod
043
044  Method mReadMethod;
045  public Method getReadMethod ()
046  { return mReadMethod; }
047
048  //-------------------------------------
049  // property writeMethod
050
051  Method mWriteMethod;
052  public Method getWriteMethod ()
053  { return mWriteMethod; }
054
055  //-------------------------------------
056  // property propertyDescriptor
057
058  IndexedPropertyDescriptor mIndexedPropertyDescriptor;
059  public IndexedPropertyDescriptor getIndexedPropertyDescriptor ()
060  { return mIndexedPropertyDescriptor; }
061
062  //-------------------------------------
063  /**
064   *
065   * Constructor
066   **/
067  public BeanInfoIndexedProperty 
068    (Method pReadMethod,
069     Method pWriteMethod,
070     IndexedPropertyDescriptor pIndexedPropertyDescriptor)
071  {
072    mReadMethod = pReadMethod;
073    mWriteMethod = pWriteMethod;
074    mIndexedPropertyDescriptor = pIndexedPropertyDescriptor;
075  }
076
077  //-------------------------------------
078}