jena-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andy Seaborne <>
Subject Re: Dataset.listNames return type
Date Sun, 06 Feb 2011 22:14:07 GMT
List<T> list = Iter.toList(iterator<T>)

It's not guaranteed to be a NiceIterator<String> because Dataset is an 
interface.  (However, it's unlikely to see a second implementation 
because it's pulling up from DatasetGraph.)

The original ExtendedIteror/NiceIterator code was specific to triples, 
then we generic'ed the code base but Iter had been necessary for me by then.


On 06/02/11 20:44, Benson Margulies wrote:
> Dataset.listNames() in fact returns a NiceIterator<String>, but is
> declared to return a plain iterator? Could we change that? I'm
> suffering from concurrent mod exceptions and I'd like to call toList
> without generic type casting pain.

View raw message