KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > myfaces > util > IteratorEnumeration


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

16 package org.apache.myfaces.util;
17
18 import java.util.Enumeration JavaDoc;
19 import java.util.Iterator JavaDoc;
20
21
22 /**
23  * @author Anton Koinov (latest modification by $Author: matze $)
24  * @version $Revision: 1.5 $ $Date: 2004/10/13 11:51:01 $
25  *
26  * $Log: IteratorEnumeration.java,v $
27  * Revision 1.5 2004/10/13 11:51:01 matze
28  * renamed packages to org.apache
29  *
30  * Revision 1.4 2004/07/01 22:05:15 mwessendorf
31  * ASF switch
32  *
33  * Revision 1.3 2004/03/30 07:40:24 dave0000
34  * *** empty log message ***
35  *
36  * Revision 1.2 2004/03/29 09:00:56 manolito
37  * copyright header
38  */

39 public class IteratorEnumeration implements Enumeration JavaDoc
40 {
41     Iterator JavaDoc _it;
42
43     public IteratorEnumeration(Iterator JavaDoc it)
44     {
45         _it = it;
46     }
47
48     public boolean hasMoreElements()
49     {
50         return _it.hasNext();
51     }
52
53     public Object JavaDoc nextElement()
54     {
55         return _it.next();
56     }
57 }
58
Popular Tags