APISonar


java.util.ArrayList.hasNext

> java > util > ArrayList > hasNext
java APIs util APIs ArrayList APIs hasNext APIs

Example 1
private ArrayList order                    = null;

    public Object clone()
    {
        OrderedJSONObject clone = (OrderedJSONObject)super.clone();
        Iterator order = clone.getOrder();
        ArrayList orderList = new ArrayList();
        while (order.hasNext())
        {
            orderList.add(order.next());
            clone.order = orderList;
        }
        return clone;
    }
Example 2
private ArrayList properties = new ArrayList();

	protected void checkPropertyColumnDuplication(Set distinctColumns, Iterator properties) 
	throws MappingException {
		while ( properties.hasNext() ) {
			Property prop = (Property) properties.next();
			if ( prop.getValue() instanceof Component ) { //TODO: remove use of instanceof!
				Component component = (Component) prop.getValue();
				checkPropertyColumnDuplication( distinctColumns, component.getPropertyIterator() );
			}
			else {
				if ( prop.isUpdateable() || prop.isInsertable() ) {
					checkColumnDuplication( distinctColumns, prop.getColumnIterator() );
				}
			}
		}
	}
Example 3
private ArrayList children = null; //a list of non-content nodes

    private int getVisibleChildIndex(DocumentElement de) {
        int index = 0;
        Iterator children = getDocumentElement().getChildren().iterator();
        while(children.hasNext()) {
            DocumentElement child = (DocumentElement)children.next();
            if(child.equals(de)) return index;
            
            //skip text and error tokens
            if(!child.getType().equals(XML_CONTENT)
                    && !child.getType().equals(XML_ERROR)
                    && !child.getType().equals(XML_COMMENT)) index++;
        }
        return -1;
    }