Package org.basex.query.value.array
Class ArrayBuilder
java.lang.Object
org.basex.query.value.array.ArrayBuilder
A builder for creating an
XQArray by prepending and appending elements.- Author:
- BaseX Team 2005-21, BSD License, Leo Woerteler
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
ArrayBuilder
public ArrayBuilder()
-
-
Method Details
-
prepend
Adds an element to the start of the array.- Parameters:
elem- element to add
-
append
Adds an element to the end of the array.- Parameters:
elem- element to add
-
append
Appends the given array to this builder.- Parameters:
arr- array to append
-
freeze
Creates anXQArraycontaining the elements of this builder.- Returns:
- resulting array
-
toString
-