APIdia Launch Partner
Top Inners Fields Constructors Methods
sun.net.www

public Class HeaderParser

extends Object
Class Inheritance
Imports
java.util.Iterator, .Locale, .OptionalInt

Nested and Inner Type Summary

Modifier and TypeClass and Description
pack-priv class

Field Summary

Modifier and TypeField and Description
pack-priv int
pack-priv int
pack-priv String
pack-priv String[][]

Constructor Summary

AccessConstructor and Description
public
private

Method Summary

Modifier and TypeMethod and Description
public int
findInt(String k, int Default)

public OptionalInt
public String
findKey(int i)

public String
findValue(int i)

public String
public String
findValue(String k, String Default)

public Iterator<String>
keys()

private void
public HeaderParser
subsequence(int start, int end)

create a new HeaderParser from this, whose keys (and corresponding values) range from "start" to "end-1"

public String
toString()

Overrides java.lang.Object.toString.

Returns a string representation of the object.

public Iterator<String>
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAllwaitwaitwait

Field Detail

asizeback to summary
pack-priv int asize
nkeysback to summary
pack-priv int nkeys
rawback to summary
pack-priv String raw
tabback to summary
pack-priv String[][] tab

Constructor Detail

HeaderParserback to summary
public HeaderParser(String raw)
HeaderParserback to summary
private HeaderParser()

Method Detail

findIntback to summary
public int findInt(String k, int Default)
findIntback to summary
public OptionalInt findInt(String k)
findKeyback to summary
public String findKey(int i)
findValueback to summary
public String findValue(int i)
findValueback to summary
public String findValue(String key)
findValueback to summary
public String findValue(String k, String Default)
keysback to summary
public Iterator<String> keys()
parseback to summary
private void parse()
subsequenceback to summary
public HeaderParser subsequence(int start, int end)

create a new HeaderParser from this, whose keys (and corresponding values) range from "start" to "end-1"

toStringback to summary
public String toString()

Overrides java.lang.Object.toString.

Doc from java.lang.Object.toString.

Returns a string representation of the object. Satisfying this method's contract implies a non-null result must be returned.

valuesback to summary
public Iterator<String> values()
sun.net.www back to summary

pack-priv Class HeaderParser.ParserIterator

extends Object
implements Iterator<String>
Class Inheritance
All Implemented Interfaces
java.util.Iterator

Field Summary

Modifier and TypeField and Description
pack-priv int
pack-priv boolean

Constructor Summary

AccessConstructor and Description
pack-priv
ParserIterator(boolean returnValue)

Method Summary

Modifier and TypeMethod and Description
public boolean
hasNext()

Implements java.util.Iterator.hasNext.

Returns true if the iteration has more elements.

public String
next()

Implements java.util.Iterator.next.

Returns the next element in the iteration.

public void
remove()

Overrides default java.util.Iterator.remove.

Removes from the underlying collection the last element returned by this iterator (optional operation).

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

indexback to summary
pack-priv int index
returnsValueback to summary
pack-priv boolean returnsValue

Constructor Detail

ParserIteratorback to summary
pack-priv ParserIterator(boolean returnValue)

Method Detail

hasNextback to summary
public boolean hasNext()

Implements java.util.Iterator.hasNext.

Doc from java.util.Iterator.hasNext.

Returns true if the iteration has more elements. (In other words, returns true if next would return an element rather than throwing an exception.)

nextback to summary
public String next()

Implements java.util.Iterator.next.

Doc from java.util.Iterator.next.

Returns the next element in the iteration.

removeback to summary
public void remove()

Overrides default java.util.Iterator.remove.

Doc from java.util.Iterator.remove.

Removes from the underlying collection the last element returned by this iterator (optional operation). This method can be called only once per call to next.

The behavior of an iterator is unspecified if the underlying collection is modified while the iteration is in progress in any way other than by calling this method, unless an overriding class has specified a concurrent modification policy.

The behavior of an iterator is unspecified if this method is called after a call to the forEachRemaining method.