yast2-core
Public Member Functions | Private Attributes | Friends | List of all members
Y2SystemNamespace Class Reference

#include <Y2SystemNamespace.h>

Inheritance diagram for Y2SystemNamespace:
Y2Namespace

Public Member Functions

 Y2SystemNamespace (Y2Namespace *local_ns)
 
virtual ~Y2SystemNamespace ()
 
virtual const string name () const
 what namespace do we implement
 
virtual const string filename () const
 used for error reporting
 
virtual YCPValue evaluate (bool)
 called when evaluating the import statement
 
virtual Y2FunctioncreateFunctionCall (const string name, constFunctionTypePtr type)
 
void useRemote (Y2ProgramComponent *sender)
 
void useLocal ()
 
- Public Member Functions inherited from Y2Namespace
 Y2Namespace ()
 
virtual ~Y2Namespace ()
 
void finish ()
 
virtual unsigned int symbolCount () const
 gives the number of symbol declarations
 
virtual SymbolEntryPtr symbolEntry (unsigned int position) const
 access to definitions of this namespace
 
virtual string toString () const
 unparse. useful for debugging
 
string symbolsToString () const
 
virtual SymbolTabletable () const
 get our whole symbol table?
 
void createTable ()
 
void pushToStack ()
 
void popFromStack ()
 
virtual void initialize ()
 

Private Attributes

Y2Namespacem_local_ns
 
Y2ProgramComponentm_remote_sender
 
bool m_use_remote
 
vector< Y2SystemFunction * > m_functions
 
string m_name
 

Friends

class Y2SystemFunction
 

Additional Inherited Members

- Protected Types inherited from Y2Namespace
typedef vector< SymbolEntryPtr > symbols_t
 
- Protected Member Functions inherited from Y2Namespace
unsigned int addSymbol (SymbolEntryPtr sentry)
 
void enterSymbol (SymbolEntryPtr sentry, Point *point=0)
 
SymbolEntryPtr lookupSymbol (const char *name) const
 
void releaseSymbol (unsigned int position)
 
- Protected Attributes inherited from Y2Namespace
SymbolTablem_table
 
unsigned int m_symbolcount
 
symbols_t m_symbols
 
bool m_initialized
 

Constructor & Destructor Documentation

Y2SystemNamespace::Y2SystemNamespace ( Y2Namespace local_ns)
Y2SystemNamespace::~Y2SystemNamespace ( )
virtual

References Y2Namespace::m_table.

Member Function Documentation

Y2Function * Y2SystemNamespace::createFunctionCall ( const string  name,
constFunctionTypePtr  type 
)
virtual

Creates a function call instance, which can be used to call a function from this namespace. The object is NOT owned anymore by this instance, the caller can (and should) delete it.

Parameters
namename of the required function
typethe type of the function (needed for overloading)
Returns
an object, that can be used to call the function, or NULL on error

Implements Y2Namespace.

References SymbolEntry::c_function, Y2Namespace::createFunctionCall(), SymbolTable::find(), m_functions, m_local_ns, m_name, m_remote_sender, m_use_remote, name(), Y2Namespace::name(), TableEntry::sentry(), Y2Namespace::table(), y2debug, and Y2SystemFunction.

YCPValue Y2SystemNamespace::evaluate ( bool  cse)
virtual

called when evaluating the import statement

Implements Y2Namespace.

References Y2Namespace::evaluate(), and m_local_ns.

const string Y2SystemNamespace::filename ( ) const
virtual

used for error reporting

Implements Y2Namespace.

const string Y2SystemNamespace::name ( ) const
virtual

what namespace do we implement

Reimplemented from Y2Namespace.

References m_name.

Referenced by createFunctionCall().

void Y2SystemNamespace::useLocal ( )
void Y2SystemNamespace::useRemote ( Y2ProgramComponent sender)

Friends And Related Function Documentation

friend class Y2SystemFunction
friend

Referenced by createFunctionCall().

Member Data Documentation

vector<Y2SystemFunction*> Y2SystemNamespace::m_functions
private
Y2Namespace* Y2SystemNamespace::m_local_ns
private
string Y2SystemNamespace::m_name
private
Y2ProgramComponent* Y2SystemNamespace::m_remote_sender
private

Referenced by createFunctionCall(), and useRemote().

bool Y2SystemNamespace::m_use_remote
private

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

Generated on a sunny day for yast2-core by doxygen 1.8.2