Cutelee 6.1.0
Public Member Functions | Properties | List of all members
BlockNode Class Reference
Inheritance diagram for BlockNode:
Inheritance graph
[legend]

Public Member Functions

 BlockNode (const QString &blockName, QObject *parent={})
 
void addParent (NodeList)
 
SafeString getSuper () const
 
QString name () const
 
NodeList nodeList () const
 
void render (OutputStream *stream, Context *c) const override
 
void setNodeList (const NodeList &list) const
 
void setNodeParent (BlockNode *)
 
BlockNodetakeNodeParent ()
 
- Public Member Functions inherited from Cutelee::Node
 Node (QObject *parent={})
 
 ~Node () override
 

Properties

Cutelee::SafeString super
 

Additional Inherited Members

- Protected Member Functions inherited from Cutelee::Node
TemplateImpl * containerTemplate () const
 
void streamValueInContext (OutputStream *stream, const QVariant &input, Cutelee::Context *c) const
 

Detailed Description

Definition at line 42 of file block.h.

Constructor & Destructor Documentation

◆ BlockNode()

BlockNode::BlockNode ( const QString blockName,
QObject *  parent = {} 
)

Definition at line 93 of file block.cpp.

◆ ~BlockNode()

BlockNode::~BlockNode ( )
override

Definition at line 99 of file block.cpp.

Member Function Documentation

◆ getSuper()

SafeString BlockNode::getSuper ( ) const

Returns the block overridden by this one rendered in context.

Definition at line 145 of file block.cpp.

References Cutelee::OutputStream::clone(), Cutelee::RenderContext::contains(), Cutelee::RenderContext::data(), Cutelee::markSafe(), render(), and Cutelee::Context::renderContext().

◆ name()

QString BlockNode::name ( ) const

Definition at line 164 of file block.cpp.

◆ nodeList()

NodeList BlockNode::nodeList ( ) const

Definition at line 162 of file block.cpp.

◆ render()

void BlockNode::render ( OutputStream stream,
Context c 
) const
overridevirtual

Reimplement this to render the template in the Context c.

This will also involve calling render on and child nodes.

Implements Cutelee::Node.

Definition at line 103 of file block.cpp.

References Cutelee::RenderContext::data(), Cutelee::Context::insert(), Cutelee::Context::pop(), Cutelee::Context::push(), Cutelee::NodeList::render(), and Cutelee::Context::renderContext().

Referenced by getSuper().

◆ setNodeList()

void BlockNode::setNodeList ( const NodeList list) const

Definition at line 101 of file block.cpp.

Property Documentation

◆ super

Cutelee::SafeString BlockNode::super
read

Definition at line 45 of file block.h.