LabelIterator
Contains the methods for iterating through a list of labels. For information about iterators, see Iterators.
Example usage:
// Gets the iterator that iterates all labels
// in the account.
var iterator = AdsApp.labels().get();
// Loops through all labels in the account.
while (iterator.hasNext()) {
var label = iterator.next();
}
Method Name | Return Type | Description |
---|---|---|
hasNext | Boolean | Gets a Boolean value that indicates whether this iterator has more elements. |
next | Label | Advances the iterator and returns the next label. |
totalNumEntities | int | Gets the number of labels that matched the selector's selection criteria. |
Gets a Boolean value that indicates whether this iterator has more elements.
Type | Description |
---|---|
Boolean | Is true if this iterator has more elements; otherwise, false. |
Advances the iterator and returns the next label.
Type | Description |
---|---|
Label | The next label in the iterator. |
Gets the number of labels that matched the selector's selection criteria.
Type | Description |
---|---|
int | The number of labels that matched the selector's selection criteria. |