Loading...
Searching...
No Matches
by::genericOrigin Class Reference
Inheritance diagram for by::genericOrigin:
by::baseObj by::node by::statable by::frameInteractable

Public Types

typedef std::vector< std::string > strings
 

Public Member Functions

 genericOrigin (const origin &org, const strings &paramNames)
 
const baseObjgetOrigin () const override
 
const strings & getParamNames () const
 
priorType prioritize (const args &a) const override
 
str eval (const args &a) override
 
str infer () const override
 
scopesubs () override
 
const std::map< std::string, tstr< obj > > & getCache () const
 
void inFrame (const bicontainable *args) const override
 
void outFrame () const override
 
- Public Member Functions inherited from by::baseObj
state getState () const override
 
void setState (state new1) override
 
const srcgetSrc () const override
 
virtual const nodegetSubPod () const
 Retrieves a sub-pod represented as a node.
 
virtual baseObjmake () const
 
const modifiergetModifier () const override
 
- Public Member Functions inherited from by::node
me & operator[] (const std::string &name)
 
const me & operator[] (const std::string &name) const BY_CONST_FUNC(operator[](name))
 
me & operator[] (const std::string *it)
 
const me & operator[] (const std::string *it) const BY_CONST_FUNC(operator[](it))
 
me & operator[] (const nchar *name)
 
const me & operator[] (const nchar *name) const BY_CONST_FUNC(operator[](name))
 
nbool in (const node &elem) const
 
nbool in (const node *elem) const
 
const scopesubs () const BY_CONST_FUNC(subs()) virtual tstr< nbicontainer > mySubs() const
 Returns a tstr to a container of immediate sub-nodes (excluding inherited or chained ones).
 
const nodepromote (const node &it) const
 
const nodepromote (const node *it) const BY_SIDE_FUNC(promote)
 
template<typename T >
T * sub (std::function< nbool(const std::string &, const T &)> l)
 
template<typename T >
const T * sub (std::function< nbool(const std::string &, const T &)> l) const BY_CONST_FUNC(sub< T >(l)) template< typename T
 
template<typename T = me>
const T * sub () const BY_CONST_FUNC(sub< T >()) template< typename T
 
template<typename T = me>
T * sub (const std::string *it) BY_SIDE_FUNC(sub)
 
template<typename T = me>
const T * sub (const std::string &name) const BY_CONST_FUNC(sub< T >(name)) template< typename T
 
template<typename T = me>
T * sub (const std::string *name, const args &a) BY_SIDE_FUNC(name
 
template<typename T = me>
const T * sub (const std::string &name, const args &a) const BY_CONST_FUNC(sub< T >(name
 
template<typename T = me>
const T a const T * sub (const std::string *name, const args &a) const BY_CONST_FUNC(sub< T >(name
 
template<typename T >
const T a const T a tnarr< T, strTactic > subAll (std::function< nbool(const std::string &, const T &)> l) const
 
template<typename T = me>
tnarr< T, strTactic > subAll () const
 
template<typename T = me>
tpriorities< T > subAll (const std::string &name) const
 
template<typename T = me>
tpriorities< T > subAll (const std::string *it) const BY_SIDE_FUNC(subAll< T >) template< typename T
 
template<typename T = me>
tpriorities< T > subAll (const std::string &name, const args &a) const
 
template<typename T = me>
tpriorities< T > subAll (const std::string *name, const args *a) const BY_SIDE_FUNC(name
 
tpriorities< T > subAll< T > tpriorities ())
 
template<typename T = me>
tpriorities< T > subAll (const std::string *name, const args &a) const BY_SIDE_FUNC(name
 
tpriorities< T > subAll< T > tpriorities ())
 
bool canEval (const args &a) const
 
priorType prioritize (const args *it) const BY_SIDE_FUNC(it
 
str eval (const args *it) BY_SIDE_FUNC(eval)
 
str eval (const std::string &name, const args &a)
 
str eval (const std::string &name, const args *a) BY_SIDE_FUNC(a
 
str eval (name, a)
 
str str ())
 
str eval (const std::string *name, const args &a) BY_SIDE_FUNC(name
 
str eval str ())
 
str eval (const std::string *name, const args *a) BY_SIDE_FUNC(name &&a
 
str eval str ())
 
str eval (const std::string &name)
 
str eval (const std::string *it) BY_SIDE_FUNC(eval)
 
str eval ()
 
virtual void rel ()
 
template<typename T >
nbool is () const
 
nbool is (const typeProvidable &to) const
 
nbool is (const typeProvidable *it) const BY_SIDE_FUNC(is)
 
nbool is (const type &to) const
 
nbool is (const type *it) const BY_SIDE_FUNC(is)
 
template<typename T >
tstr< T > as () const
 
str as (const typeProvidable &to) const
 
str as (const typeProvidable *it) const BY_SIDE_FUNC(as)
 
str as (const type &to) const
 
str as (const type *it) const BY_SIDE_FUNC(as)
 
template<typename T >
nbool isImpli () const
 
virtual nbool isImpli (const type &to) const
 
nbool isImpli (const typeProvidable &to) const
 
nbool isImpli (const typeProvidable *it) const BY_SIDE_FUNC(isImpli)
 
template<typename T >
tstr< T > asImpli () const
 
virtual str asImpli (const type &to) const
 
str asImpli (const typeProvidable &to) const
 
str asImpli (const typeProvidable *it) const BY_SIDE_FUNC(asImpli)
 
virtual nbool isComplete () const
 
virtual void accept (const visitInfo &i, visitor &v)
 
void inFrame (const bicontainable *args) const override
 
void outFrame () const override
 
virtual void inFrame (const bicontainable *args) const=0
 
void inFrame () const
 
virtual void outFrame () const=0
 
- Public Member Functions inherited from by::frameInteractable
void inFrame () const
 

Protected Member Functions

str _onEvalSub (node &sub, const args &a) override
 Protected virtual method for evaluating a sub-node.
 
- Protected Member Functions inherited from by::baseObj
 baseObj ()=default
 Default constructor for baseObj.
 
 baseObj (const baseObj *org, nbool isScripted)
 Constructs a baseObj from an existing origin object.
 
void _setSrc (const src &s) override
 
virtual void _inFrame (frame &fr, const bicontainable *args) const
 Enters this object's frame into the current execution stack.
 
virtual void _setType (const mgdType &new1)
 Sets the script type for this base object.
 
virtual void _setModifier (const modifier &mod)
 
virtual str _onBeforeCtor ()
 Hook method called before the object's constructor is fully executed.
 
- Protected Member Functions inherited from by::node
void _setSrc (const src *it) BY_SIDE_FUNC(_setSrc)
 

Additional Inherited Members

- Public Attributes inherited from by::node
T sub name
 
T sub nullptr
 
tpriorities< T > subAll< T > name
 
priorType prioritize it
 
priorType prioritize NO_MATCH
 
str eval name
 
- Static Public Attributes inherited from by::baseObj
static const std::string COMMON_NAME = "@common"
 
static const std::string EXPAND_NAME = "@expand"
 
- Protected Attributes inherited from by::baseObj
tstr< baseObj_org
 

Member Function Documentation

◆ _onEvalSub()

str by::genericOrigin::_onEvalSub ( node & sub,
const args & a )
overrideprotectedvirtual

Protected virtual method for evaluating a sub-node.

This method is a crucial part of the evaluation mechanism, allowing derived classes to define how a specific sub-node is evaluated within the context of the current node.

Parameters
subThe sub-node to be evaluated.
aThe arguments for evaluation.
Returns
The result of the evaluation as a str object.

Reimplemented from by::baseObj.

◆ eval()

str by::genericOrigin::eval ( const args & a)
overridevirtual

Reimplemented from by::baseObj.

◆ getOrigin()

const baseObj & by::genericOrigin::getOrigin ( ) const
overridevirtual

Reimplemented from by::baseObj.

◆ infer()

str by::genericOrigin::infer ( ) const
overridevirtual

getType() returns what it is. opposite to it, this returns what this class will represents after evaluation.

for example, the expr class has derived from this node class. and if an user call the funcs to get type of it, class 'ntype' of 'expr' will be returned. but if that user call the 'infer()' then the 'expr' object evaluate its terms and returns it as a node from the output. it could be an integer if it was addExpr and all terms are constructed with integers.

and also this func requires frames. means that you have to interact frame first before call this func.

Remarks
some derived class of node may require to call this function first by verifier. if you call this function without calling verifier previously will damage then process.

Reimplemented from by::node.

◆ inFrame()

void by::genericOrigin::inFrame ( const bicontainable * args) const
overridevirtual

Reimplemented from by::baseObj.

◆ outFrame()

void by::genericOrigin::outFrame ( ) const
overridevirtual

Reimplemented from by::baseObj.

◆ prioritize()

priorType by::genericOrigin::prioritize ( const args & a) const
overridevirtual

Reimplemented from by::baseObj.

◆ subs()

scope & by::genericOrigin::subs ( )
overridevirtual

Reimplemented from by::baseObj.


The documentation for this class was generated from the following file:
to Top