FileDocCategorySizeDatePackage
StringListImpl.javaAPI DocAzureus 3.0.3.42541Mon Feb 27 15:10:36 GMT 2006org.gudy.azureus2.core3.config.impl

StringListImpl

public class StringListImpl extends Object implements org.gudy.azureus2.core3.config.StringList
author
Olivier Chalouhi

Fields Summary
List
list
Constructors Summary
public StringListImpl()

		this.list = new ArrayList();
	
public StringListImpl(StringListImpl _list)

		list = new ArrayList(_list.getList());
	
StringListImpl(List _list)

		//Atempt to convert list to String List
		this();		
		Iterator iter = _list.iterator();
		while(iter.hasNext()) {
			Object obj = iter.next();
			if(obj instanceof String) {
				list.add(obj);
			} else if(obj instanceof byte[]) {
				list.add(ConfigurationManager.bytesToString((byte[]) obj));
			} else if(obj instanceof Object) {
				list.add(obj.toString());
			}
		}		
	
Methods Summary
public voidadd(java.lang.String str)

		list.add(str);
	
public voidadd(int index, java.lang.String str)

		list.add(index,str);
	
public booleancontains(java.lang.String str)

		return list.contains(str);
	
public java.lang.Stringget(int i)

		return (String) list.get(i);
	
java.util.ListgetList()

		return list;
	
public intindexOf(java.lang.String str)

		return list.indexOf(str);
	
public org.gudy.azureus2.core3.config.StringIteratoriterator()

		return new StringIteratorImpl(list.iterator());
	
public java.lang.Stringremove(int index)

		return (String)list.remove(index);
	
public intsize()

		return list.size();