Skip to end of banner
Go to start of banner

Collection Supplier

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 10 Next »

Overview

Provides information about collections of items.

Details

Name:

Collection Supplier

Prefix:

collection(optional)

Supported Content:

Collections, such as lists, sets and arrays.

Provided By:

Reporting for Confluence

Supported Keys

The following are the list of keys which this supplier will return a value for.

Key

Content Types

Return Type

Description

size

Collection

Number

The number of items in the collection.

is empty

Collection

Boolean

Test if the collection is empty.

first

Collection

Anything

(Since 2.0.0) Returns the first item in the collection, if anything is present. If there is only one item in the collection then you must use this parameter.

last

Collection

Anything

(Since 2.0.0) Returns the last item in the collection, if anything is present.

[X]

Collection

Anything

(Since 2.0.0) Returns the X'th item in the collection, where X is a number between 1 and 'size'.

join with [X]

Collection

Text

Since 3.0.0) Joins the 'to string' value of all the collection contents into a Text, with the '[X]' value is put between each item. e.g.: 'text:join with ", "'.

random

Collection

Anything

(Since 3.1.0) Returns a random item from the provided list of elements.

shuffle

Collection

Collection

(Since 3.1.0) Returns the collection of items but scrambles the order of the elements.

reverse

Collection

Collection

(Since 3.2.0) Returns the collection of items in reverse order.

collect [X]

Collection

Collection

(Since 4.0.0) Returns a collection of the same length made up of sub-values of each item in this collection with the specified keyword of 'X'.

  • No labels