The OpenD Programming Language

ElementCollection

A collection of elements which forwards methods to the children.

Constructors

this
this(Element e)
this
this(Element e, string selector)
this
this(Element[] e)

Members

Functions

collect
string collect(string separator)

Collects strings from the collection, concatenating them together Kinda like running reduce and ~= on it.

empty
bool empty()
front
Element front()

And input range primitives so we can foreach over this

opBinary
ElementCollection opBinary(ElementCollection rhs)

Concatenates two ElementCollection together.

opDispatch
ElementCollection opDispatch(T t)

Forward method calls to each individual element of the collection returns this so it can be chained.

opIndex
ElementCollection opIndex(string selector)
opIndex
Element opIndex(int i)
opSlice
Element[] opSlice()

if you slice it, give the underlying array for easy forwarding of the collection to range expecting algorithms or looping over.

popFront
void popFront()

And input range primitives so we can foreach over this

wrapIn
ElementCollection wrapIn(Element what)

Calls Element.wrapIn on each member of the collection, but clones the argument what for each one.

See Also

Meta