ONE - On-device Neural Engine
Loading...
Searching...
No Matches
coco::Def Class Referencefinal

#include <Def.h>

Public Member Functions

 Def (Object::Producer *producer)
 
 ~Def ()
 
Objectvalue (void) const
 
void value (Object *value)
 
Object::Producer * producer (void) const
 

Detailed Description

Definition at line 25 of file Def.h.

Constructor & Destructor Documentation

◆ Def()

coco::Def::Def ( Object::Producer *  producer)
inline

Definition at line 28 of file Def.h.

28 : _producer{producer}
29 {
30 // DO NOTHING
31 }
Object::Producer * producer(void) const
Definition Def.h:43

◆ ~Def()

coco::Def::~Def ( )
inline

Definition at line 34 of file Def.h.

34{ value(nullptr); }
Object * value(void) const
Definition Def.h:37

References value().

Member Function Documentation

◆ producer()

Object::Producer * coco::Def::producer ( void  ) const
inline

Definition at line 43 of file Def.h.

43{ return _producer; }

Referenced by coco::producer().

◆ value() [1/2]

void coco::Def::value ( Object value)

Definition at line 24 of file Def.cpp.

25{
26 if (_value)
27 {
28 _value->def(nullptr);
29 _value = nullptr;
30 }
31
32 assert(_value == nullptr);
33
34 if (value)
35 {
36 _value = value;
37 _value->def(this);
38 }
39
40 assert(_value == value);
41}
Def * def(void) const
Definition Object.cpp:33

References coco::Object::def(), and value().

◆ value() [2/2]

Object * coco::Def::value ( void  ) const
inline

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