wiRedPanda
Logic Circuit Simulator
Loading...
Searching...
No Matches
ElementInfo< And > Struct Reference

Static Public Member Functions

static ElementMetadata metadata ()

Static Public Attributes

static constexpr ElementConstraints constraints
static const bool registered

Detailed Description

Definition at line 11 of file And.cpp.

Member Function Documentation

◆ metadata()

ElementMetadata ElementInfo< And >::metadata ( )
inlinestatic

Definition at line 23 of file And.cpp.

References constraints, and metadataFromConstraints().

Member Data Documentation

◆ constraints

ElementConstraints ElementInfo< And >::constraints
staticconstexpr
Initial value:
{
.type = ElementType::And,
.group = ElementGroup::Gate,
.minInputSize = 2,
.maxInputSize = 8,
.minOutputSize = 1,
.maxOutputSize = 1,
.canChangeAppearance = true,
}

Definition at line 12 of file And.cpp.

Referenced by metadata().

◆ registered

const bool ElementInfo< And >::registered
inlinestatic
Initial value:
= []() {
ElementFactory::registerCreator(constraints.type, [] { return new And(); });
return true;
}()
static void registerCreator(ElementType type, std::function< GraphicElement *()> creator)
Registers a creator lambda for type, used by buildElement().
static void registerMetadata(const ElementMetadata &meta)
Registers meta in the global map (called once per element type at startup).
static ElementMetadata metadata()
Definition And.cpp:23
static constexpr ElementConstraints constraints
Definition And.cpp:12

Definition at line 38 of file And.cpp.


The documentation for this struct was generated from the following file: