A11 (C++ runtime)
Native C++ implementation of the A11 streaming action runtime
Loading...
Searching...
No Matches
a11::flow::FlowBuilder Class Reference

An implemented flow or interface, constructed with native typed helpers. More...

#include <cpp/a11/flow/document.h>

Public Member Functions

 FlowBuilder (std::string name, bool interface_only=false)
 
FlowPlan & interface ()
 
const FlowPlan & interface () const
 
absl::Status AddPort (std::string name, syntax::TypeExpression type, syntax::PortDirection direction=syntax::PortDirection::kInput, bool unary=true, bool required=false, std::string description={})
 
absl::Status AddStatement (Statement statement)
 
absl::Status AddInitialize (std::string_view name, const Expression &value, std::optional< syntax::TypeExpression > type={})
 
absl::Status AddPipe (const Expression &value, const Expression &destination)
 
absl::Status AddImport (std::string reference, std::string alias, std::string symbol={})
 
absl::Status AddDeclaration (const FlowPlan &interface)
 
absl::Status AddStruct (DtoPlan shape)
 
absl::StatusOr< std::string > Emit () const
 

Detailed Description

An implemented flow or interface, constructed with native typed helpers.

Constructor & Destructor Documentation

◆ FlowBuilder()

a11::flow::FlowBuilder::FlowBuilder ( std::string  name,
bool  interface_only = false 
)
explicit

Member Function Documentation

◆ AddDeclaration()

absl::Status a11::flow::FlowBuilder::AddDeclaration ( const FlowPlan &  interface)

◆ AddImport()

absl::Status a11::flow::FlowBuilder::AddImport ( std::string  reference,
std::string  alias,
std::string  symbol = {} 
)

◆ AddInitialize()

absl::Status a11::flow::FlowBuilder::AddInitialize ( std::string_view  name,
const Expression &  value,
std::optional< syntax::TypeExpression >  type = {} 
)

◆ AddPipe()

absl::Status a11::flow::FlowBuilder::AddPipe ( const Expression &  value,
const Expression &  destination 
)

◆ AddPort()

absl::Status a11::flow::FlowBuilder::AddPort ( std::string  name,
syntax::TypeExpression  type,
syntax::PortDirection  direction = syntax::PortDirection::kInput,
bool  unary = true,
bool  required = false,
std::string  description = {} 
)

◆ AddStatement()

absl::Status a11::flow::FlowBuilder::AddStatement ( Statement  statement)

◆ AddStruct()

absl::Status a11::flow::FlowBuilder::AddStruct ( DtoPlan  shape)

◆ Emit()

absl::StatusOr< std::string > a11::flow::FlowBuilder::Emit ( ) const

◆ interface() [1/2]

FlowPlan & a11::flow::FlowBuilder::interface ( )
inline

◆ interface() [2/2]

const FlowPlan & a11::flow::FlowBuilder::interface ( ) const
inline

The documentation for this class was generated from the following files: