sk.uniba.euromath.document.schema.impl.add
Class ComputeInsertLists

java.lang.Object
  extended by sk.uniba.euromath.document.schema.impl.add.ComputeInsertLists

public final class ComputeInsertLists
extends Object

Serves for computation of list of insertlists. These InsertLists describes new elements, that can be added to contents of some element. Immutable, thread-safe.

Author:
Martin Vysny

Constructor Summary
ComputeInsertLists(SchemaImpl schema)
          Constructor.
 
Method Summary
 List<InsertListImpl> getInsertableElements(sk.baka.ikslibs.ptr.DomPointer ptr)
          Tries to insert new element into children of given element.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ComputeInsertLists

public ComputeInsertLists(SchemaImpl schema)
Constructor.

Parameters:
schema - the schema instance.
Method Detail

getInsertableElements

public List<InsertListImpl> getInsertableElements(sk.baka.ikslibs.ptr.DomPointer ptr)
Tries to insert new element into children of given element. Insertion place is specified by insertPlace and pos parameters. If insertPlace denotes Element, then new element must be inserted before this Element. In this case, the pos argument is ignored. If insertPlace denotes CharacterData, then pos specifies index of character, after which new element must be inserted.

Parameters:
ptr - place, where to insert new element.
Returns:
list of IlAndTailImpl objects, describing new elements, insertable into parent.
Throws:
DocumentValidityException - when validity or schema error occurs.


Copyright © 2003-2006 null. All Rights Reserved.