KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > directory > ldapstudio > apacheds > configuration > model > IndexedAttribute


1 /*
2  * Licensed to the Apache Software Foundation (ASF) under one
3  * or more contributor license agreements. See the NOTICE file
4  * distributed with this work for additional information
5  * regarding copyright ownership. The ASF licenses this file
6  * to you under the Apache License, Version 2.0 (the
7  * "License"); you may not use this file except in compliance
8  * with the License. You may obtain a copy of the License at
9  *
10  * http://www.apache.org/licenses/LICENSE-2.0
11  *
12  * Unless required by applicable law or agreed to in writing,
13  * software distributed under the License is distributed on an
14  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15  * KIND, either express or implied. See the License for the
16  * specific language governing permissions and limitations
17  * under the License.
18  *
19  */

20 package org.apache.directory.ldapstudio.apacheds.configuration.model;
21
22
23 /**
24  * This class represents an Indexed Attribute.
25  *
26  * @author <a HREF="mailto:dev@directory.apache.org">Apache Directory Project</a>
27  * @version $Rev$, $Date$
28  */

29 public class IndexedAttribute
30 {
31     /** The attribute id */
32     private String JavaDoc attributeId;
33
34     /** The cache size */
35     private int cacheSize;
36
37
38     /**
39      * Creates a new instance of IndexedAttribute.
40      *
41      * @param attributeId
42      * the attribute id
43      * @param cacheSize
44      * the cache size
45      */

46     public IndexedAttribute( String JavaDoc attributeId, int cacheSize )
47     {
48         this.attributeId = attributeId;
49         this.cacheSize = cacheSize;
50     }
51
52
53     /**
54      * Gets the attribute id.
55      *
56      * @return
57      * the attribute id
58      */

59     public String JavaDoc getAttributeId()
60     {
61         return attributeId;
62     }
63
64
65     /**
66      * Sets the attribute id.
67      *
68      * @param attributeId
69      * the new attribute id
70      */

71     public void setAttributeId( String JavaDoc attributeId )
72     {
73         this.attributeId = attributeId;
74     }
75
76
77     /**
78      * Gets the cache size.
79      *
80      * @return
81      * the cache size
82      */

83     public int getCacheSize()
84     {
85         return cacheSize;
86     }
87
88
89     /**
90      * Gets the cache size.
91      *
92      * @param cacheSize
93      * the new cache size
94      */

95     public void setCacheSize( int cacheSize )
96     {
97         this.cacheSize = cacheSize;
98     }
99
100
101     /* (non-Javadoc)
102      * @see java.lang.Object#toString()
103      */

104     public String JavaDoc toString()
105     {
106         return attributeId + " [" + cacheSize + "]";
107     }
108 }
109
Popular Tags