StatementHolder

interface StatementHolder

This interface denotes an AST-Node that can contain code. This code is stored as statements. This includes Translation units namespaces and classes as some languages, mainly scripting languages allow code placement outside of explicit functions.

The reason for not only using a statement property that encapsulates all code in an implicit compound statements is that code can be distributed between functions and an encapsulating compound statement would imply a block of code with a code region containing only the statements.

Functions

Link copied to clipboard
open fun addStatement(s: Statement)
Adds the specified statement to this statement holder.
Link copied to clipboard
@NotNull
abstract fun getStatementEdges(): @NotNull List<PropertyEdge<Statement>>
Getter to be implemented by implementing classes to gain read access to the classes member.
Link copied to clipboard
@NotNull
open fun getStatements(): @NotNull List<Statement>
Returns the list of contained statements.
Link copied to clipboard
@NotNull
open fun getStatementsPropertyEdge(): @NotNull List<PropertyEdge<Statement>>
Link copied to clipboard
abstract fun setStatementEdges(@NotNull statements: @NotNull List<PropertyEdge<Statement>>)
Link copied to clipboard
open fun setStatements(@NotNull statements: @NotNull List<Statement>)

Inheritors

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard