Edit in GitHubLog an issue

BuildingBlocks

A collection of cross reference building blocks.

Instance

Read Only

Number length

The number of objects in the collection.

Methods

BuildingBlock add( BuildingBlockTypes blockType, CharacterStyle appliedCharacterStyle, String customText, Object withProperties )

Creates a new cross reference building block.

Parameters

TypeNameDescription
BuildingBlockTypes
blockType
Type of the building block.
CharacterStyle
appliedCharacterStyle
Character style to be applied to the building block. (Optional)
String
customText
Building block custom text. Currently this is only useful in custom string building block. It is ignored for other types of building blocks. (Optional)
Object
withProperties
Initial values for properties of the new BuildingBlock (Optional)

Number count()

Displays the number of elements in the BuildingBlock.


BuildingBlock item( Mixed index )

Returns the BuildingBlock with the specified index or name.

Parameters

TypeNameDescription
Mixed
index
The index or name. Can accept: Long Integer or String.

BuildingBlock itemByRange( Mixed from, Mixed to )

Returns the BuildingBlocks within the specified range.

Parameters

TypeNameDescription
Mixed
from
The BuildingBlock, index, or name at the beginning of the range. Can accept: BuildingBlock, Long Integer or String.
Mixed
to
The BuildingBlock, index, or name at the end of the range. Can accept: BuildingBlock, Long Integer or String.

BuildingBlock firstItem()

Returns the first BuildingBlock in the collection.


BuildingBlock lastItem()

Returns the last BuildingBlock in the collection.


BuildingBlock middleItem()

Returns the middle BuildingBlock in the collection.


BuildingBlock previousItem( BuildingBlock obj )

Returns the BuildingBlock with the index previous to the specified index.

Parameters

TypeNameDescription
BuildingBlock
obj
The index of the BuildingBlock that follows the desired BuildingBlock.

BuildingBlock nextItem( BuildingBlock obj )

Returns the BuildingBlock whose index follows the specified BuildingBlock in the collection.

Parameters

TypeNameDescription
BuildingBlock
obj
The BuildingBlock whose index comes before the desired BuildingBlock.

BuildingBlock anyItem()

Returns any BuildingBlock in the collection.


BuildingBlock everyItem()

Returns every BuildingBlock in the collection.


String toSource()

Generates a string which, if executed, will return the BuildingBlock.


BuildingBlock []( Number index )

Returns the BuildingBlock with the specified index.

Parameters

TypeNameDescription
Number
index
The index.
Was this helpful?
  • Privacy
  • Terms of Use
  • Do not sell or share my personal information
  • AdChoices
Copyright © 2023 Adobe. All rights reserved.