public class InstructionChain extends Object
Instruction
s.Modifier and Type | Method and Description |
---|---|
static InstructionChain |
empty()
A safe way to retrieve an empty, shared, immutable instance.
|
static InstructionChain |
from(Collection<Instruction> collection)
Construct an instance holding the elements of the given collection.
|
static InstructionChain |
from(FrozenList<Instruction> frozenList)
Construct an instance holding the elements of the given list.
|
static InstructionChain |
from(Instruction... instructions)
Construct an instance holding the elements supplied by the given varargs array.
|
FrozenList<Instruction> |
getInstructions() |
boolean |
isEmpty()
Indicates whether or not this chain holds any
Instruction s at all. |
public static InstructionChain from(FrozenList<Instruction> frozenList)
frozenList
- holds the elements to be added. Passing null
leads to an empty
InstructionChain
being created.public static InstructionChain from(Collection<Instruction> collection)
collection
- holds the elements to be added. Passing null
leads to an empty
InstructionChain
being created.public static InstructionChain from(Instruction... instructions)
instructions
- holds the elements to be added. Passing null
leads to an empty
InstructionChain
being created.public static InstructionChain empty()
InstructionChain
instancepublic FrozenList<Instruction> getInstructions()
Instruction
s transported by this chain. Will never be null
.public boolean isEmpty()
Instruction
s at all.true
if this chain doesn't hold any Instruction
s,
false
if it does.Copyright © 2024 levigo holding gmbh. All rights reserved.