FileDocCategorySizeDatePackage
DList6.javaAPI DocExample911Sat Sep 12 03:01:00 BST 1998None

DList6

public class DList6 extends Object
Splicing a piece of a DList into another.
see
com.objectspace.jgl.DList
version
3.0.0
author
ObjectSpace, Inc.

Fields Summary
Constructors Summary
Methods Summary
public static voidmain(java.lang.String[] args)

    DList dlist1 = new DList();
    dlist1.add( "apple" );
    dlist1.add( "banana" );
    DList dlist2 = new DList();
    dlist2.add( "lotus" );
    dlist2.add( "ferrari" );
    dlist2.add( "lamborghini" );
    System.out.println( "before: dlist1 = " + dlist1 + ", dlist2 = " + dlist2 );

    DListIterator i = dlist1.begin();
    i.advance();
    DListIterator start = dlist2.begin();
    DListIterator finish = dlist2.begin();
    finish.advance( 2 );
    dlist1.splice( i, dlist2, start, finish );
    System.out.println( "after: dlist1 = " + dlist1 + ", dlist2 = " + dlist2 );