## org.codehaus.plexus.i18n
Class I18NTokenizer

    java.lang.Object
      org.codehaus.plexus.i18n.I18NTokenizer

All Implemented Interfaces:
  java.util.Iterator

    public class I18NTokenizer

extends java.lang.Object
implements java.util.Iterator

Parses the HTTP `Accept-Language` header as per section 14.4 of RFC 2068 (HTTP 1.1 header field definitions).

Version:
  $Id: I18NTokenizer.java 6675 2007-07-20 23:05:53Z olamy $
Author:
  Daniel Rall

Constructor Summary
`I18NTokenizer(java.lang.String header)` Parses the `Accept-Language` header.

Method Summary
`boolean` `hasNext()`
`java.lang.Object` `next()` Creates a `Locale` from the next element of the `Accept-Language` header.
`void` `remove()` Not implemented.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### I18NTokenizer

    public I18NTokenizer(java.lang.String header)

  Parses the `Accept-Language` header.

  Parameters:
    `header` - The `Accept-Language` header (i.e. `en, es;q=0.8, zh-TW;q=0.1`).

Method Detail

### hasNext

    public boolean hasNext()

  Specified by:
    `hasNext` in interface `java.util.Iterator`
  Returns:
    Whether there are more locales.

### next

    public java.lang.Object next()

  Creates a `Locale` from the next element of the `Accept-Language` header.

  Specified by:
    `next` in interface `java.util.Iterator`
  Returns:
    The next highest-rated `Locale`.
  Throws:
    `java.util.NoSuchElementException` - No more locales.

### remove

    public final void remove()

  Not implemented.

  Specified by:
    `remove` in interface `java.util.Iterator`

Copyright © 2011. All Rights Reserved.