Class FirstItem
Returns the first item in a collection or enumeration.
Inherited Members
Namespace: Unity.VisualScripting
Syntax
[UnitCategory("Collections")]
public sealed class FirstItem : Unit, IUnit, IGraphElementWithDebugData, IGraphElement, IGraphItem, INotifiedCollectionItem, IDisposable, IPrewarmable, IAotStubbable, IIdentifiable, IAnalyticsIdentifiable
Properties
collection
The collection.
Declaration
[DoNotSerialize]
public ValueInput collection { get; }
Property Value
Type | Description |
---|---|
ValueInput |
firstItem
The first item of the collection.
Declaration
[DoNotSerialize]
public ValueOutput firstItem { get; }
Property Value
Type | Description |
---|---|
ValueOutput |
Methods
Definition()
Declaration
protected override void Definition()
Overrides
First(Flow)
Declaration
public object First(Flow flow)
Parameters
Type | Name | Description |
---|---|---|
Flow | flow |
Returns
Type | Description |
---|---|
Object |