org.apache.wicket.util.resource.locator
Class LocaleResourceNameIterator

java.lang.Object
  extended by org.apache.wicket.util.resource.locator.LocaleResourceNameIterator
All Implemented Interfaces:
java.util.Iterator<java.lang.String>

public class LocaleResourceNameIterator
extends java.lang.Object
implements java.util.Iterator<java.lang.String>

Given a Locale it'll iterate over all possible combinations of the attrs making up the Locale. Starting the Locale provided to more 'weaker' combinations. The latest one will be no Locale in which case an empty string will be returned.

Author:
Juergen Donnerstag

Constructor Summary
LocaleResourceNameIterator(java.util.Locale locale, boolean strict)
          Construct.
 
Method Summary
 java.util.Locale getLocale()
           
 boolean hasNext()
           
 java.lang.String next()
           
 void remove()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LocaleResourceNameIterator

public LocaleResourceNameIterator(java.util.Locale locale,
                                  boolean strict)
Construct.

Parameters:
locale -
strict -
Method Detail

getLocale

public java.util.Locale getLocale()
Returns:
Locale

hasNext

public boolean hasNext()
Specified by:
hasNext in interface java.util.Iterator<java.lang.String>
See Also:
Iterator.hasNext()

next

public java.lang.String next()
Specified by:
next in interface java.util.Iterator<java.lang.String>
See Also:
Iterator.next()

remove

public void remove()
Specified by:
remove in interface java.util.Iterator<java.lang.String>
See Also:
Iterator.remove()


Copyright © 2006-2011 Apache Software Foundation. All Rights Reserved.