yast2-core
Public Types | Public Member Functions | Static Public Attributes | Protected Types | Protected Attributes | Private Member Functions | List of all members
SymbolEntry Class Reference

#include <SymbolEntry.h>

Inheritance diagram for SymbolEntry:
Rep YSymbolEntry

Public Types

enum  category_t {
  c_unspec = 0, c_global, c_module, c_variable,
  c_reference, c_function, c_builtin, c_typedef,
  c_const, c_namespace, c_self, c_predefined,
  c_filename
}
 

Public Member Functions

 SymbolEntry (const Y2Namespace *name_space, unsigned int position, const char *name, category_t cat, constTypePtr type)
 
virtual ~SymbolEntry ()
 
const Y2NamespacenameSpace () const
 
void setNamespace (const Y2Namespace *name_space)
 
virtual bool onlyDeclared () const
 
unsigned int position () const
 
void setPosition (unsigned int position)
 
bool isGlobal () const
 
void setGlobal (bool global)
 
bool isModule () const
 
bool isVariable () const
 
bool isReference () const
 
bool isFunction () const
 
bool isBuiltin () const
 
bool isNamespace () const
 
bool isSelf () const
 
bool isFilename () const
 
bool isPredefined () const
 
bool likeNamespace () const
 
const char * name () const
 
category_t category () const
 
void setCategory (category_t cat)
 
constTypePtr type () const
 
string catString () const
 
void setType (constTypePtr type)
 
virtual YCPValue setValue (YCPValue value)
 
virtual YCPValue value () const
 
void push ()
 
void pop ()
 
virtual string toString (bool with_type=true) const
 
- Public Member Functions inherited from Rep
 Rep ()
 
 Rep (const Rep &)
 
Repoperator= (const Rep &)
 
virtual ~Rep ()
 
void ref () const
 
void unref () const
 
unsigned refCount () const
 
virtual const char * repName () const
 
virtual std::ostream & dumpOn (std::ostream &str) const
 

Static Public Attributes

static UstringHash_nameHash = NULL
 
static Ustring emptyUstring = Ustring ( *( SymbolEntry::_nameHash ? SymbolEntry::_nameHash : (SymbolEntry::_nameHash = new UstringHash)), "")
 

Protected Types

typedef std::stack< YCPValuevaluestack_t
 

Protected Attributes

bool m_global
 
const Y2Namespacem_namespace
 
unsigned int m_position
 
Ustring m_name
 
category_t m_category
 
constTypePtr m_type
 
YCPValue m_value
 
valuestack_tm_recurse_stack
 

Private Member Functions

 REP_BODY (SymbolEntry)
 

Additional Inherited Members

- Static Public Member Functions inherited from Rep
static void ref (const Rep *obj_r)
 
static void unref (const Rep *obj_r)
 
- Protected Member Functions inherited from Rep
virtual void ref_to (unsigned) const
 
virtual void unref_to (unsigned) const
 

Member Typedef Documentation

typedef std::stack<YCPValue> SymbolEntry::valuestack_t
protected

Member Enumeration Documentation

Enumerator
c_unspec 
c_global 
c_module 
c_variable 
c_reference 
c_function 
c_builtin 
c_typedef 
c_const 
c_namespace 
c_self 
c_predefined 
c_filename 

Constructor & Destructor Documentation

SymbolEntry::SymbolEntry ( const Y2Namespace name_space,
unsigned int  position,
const char *  name,
category_t  cat,
constTypePtr  type 
)

constructor

SymbolEntry::~SymbolEntry ( )
virtual

Member Function Documentation

SymbolEntry::category_t SymbolEntry::category ( ) const

References m_category.

string SymbolEntry::catString ( ) const
bool SymbolEntry::isBuiltin ( ) const
inline

References c_builtin, and m_category.

bool SymbolEntry::isFilename ( ) const
inline

References c_filename, and m_category.

bool SymbolEntry::isFunction ( ) const
inline

References c_function, and m_category.

bool SymbolEntry::isGlobal ( ) const

References m_global.

bool SymbolEntry::isModule ( ) const
inline

References c_module, and m_category.

Referenced by likeNamespace().

bool SymbolEntry::isNamespace ( ) const
inline

References c_namespace, and m_category.

Referenced by likeNamespace().

bool SymbolEntry::isPredefined ( ) const
inline

References c_predefined, and m_category.

bool SymbolEntry::isReference ( ) const
inline

References c_reference, and m_category.

bool SymbolEntry::isSelf ( ) const
inline

References c_self, and m_category.

Referenced by likeNamespace().

bool SymbolEntry::isVariable ( ) const
inline

References c_variable, and m_category.

bool SymbolEntry::likeNamespace ( ) const
inline

References isModule(), isNamespace(), and isSelf().

const char * SymbolEntry::name ( ) const

References Ustring::asString(), and m_name.

const Y2Namespace * SymbolEntry::nameSpace ( ) const

References m_namespace.

Referenced by YSymbolEntry::toXml().

virtual bool SymbolEntry::onlyDeclared ( ) const
inlinevirtual

Reimplemented in YSymbolEntry.

void SymbolEntry::pop ( )

References m_recurse_stack, and m_value.

unsigned int SymbolEntry::position ( ) const

References m_position.

Referenced by setPosition().

void SymbolEntry::push ( )

References m_recurse_stack, and m_value.

SymbolEntry::REP_BODY ( SymbolEntry  )
private
void SymbolEntry::setCategory ( SymbolEntry::category_t  cat)

References m_category.

void SymbolEntry::setGlobal ( bool  global)

References m_global.

void SymbolEntry::setNamespace ( const Y2Namespace name_space)

References m_namespace.

void SymbolEntry::setPosition ( unsigned int  position)

References m_position, and position().

Referenced by Y2Namespace::finish().

void SymbolEntry::setType ( constTypePtr  type)

References m_type, and type().

YCPValue SymbolEntry::setValue ( YCPValue  value)
virtual
string SymbolEntry::toString ( bool  with_type = true) const
virtual
constTypePtr SymbolEntry::type ( ) const

References m_type.

Referenced by setType(), and toString().

YCPValue SymbolEntry::value ( ) const
virtual

Member Data Documentation

UstringHash * SymbolEntry::_nameHash = NULL
static
Ustring SymbolEntry::emptyUstring = Ustring ( *( SymbolEntry::_nameHash ? SymbolEntry::_nameHash : (SymbolEntry::_nameHash = new UstringHash)), "")
static

Referenced by Import::Import().

category_t SymbolEntry::m_category
protected
bool SymbolEntry::m_global
protected
Ustring SymbolEntry::m_name
protected
const Y2Namespace* SymbolEntry::m_namespace
protected
unsigned int SymbolEntry::m_position
protected
valuestack_t* SymbolEntry::m_recurse_stack
protected

Referenced by pop(), and push().

constTypePtr SymbolEntry::m_type
protected
YCPValue SymbolEntry::m_value
protected

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

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