lestes::lang::cplus::sem::ss_pointer Class Reference

Class for pointered types. More...

#include <ss_type.g.hh>

Inheritance diagram for lestes::lang::cplus::sem::ss_pointer:

lestes::lang::cplus::sem::ss_type lestes::intercode::ss_base lestes::intercode::intercode lestes::std::object lestes::std::mem::keystone List of all members.

Public Member Functions

ptr< ss_typewhat_get () const
 The method what_get returns the value of the field ss_pointer::what.
void what_set (const ptr< ss_type > &)
 The method what_set sets the field ss_pointer::what to the given value.
virtual ptr< ::lestes::std::list<
srp< or_ics_functional > > > 
accept_or_ics_base (ptr< or_ics_base > v)
virtual or_cv_enum accept_or_ics_base_cv (ptr< or_ics_base_cv > v)
virtual ptr< ::lestes::md::types::tm_data_type_baseaccept_ss_type2tm_type_gen_base (ptr< ss_type2tm_type_gen_base > v)
virtual void accept_ss_type_visitor (ptr< ss_type_visitor > v)
virtual ptr< reflection_listreflection_get () const
 for purposes of dumping
virtual ptr< field_list_listfield_values_get () const
 for purposes of dumping

Static Public Member Functions

static ptr< ss_typeinstance (ptr< ss_type > type)
 get the instance representing pointer to the argument type
static ptr< ss_pointercreate (ptr< ss_type > a__ss_pointer__what)
 First generated factory method for class ss_pointer.

Protected Member Functions

 ss_pointer (ptr< ss_type > a__ss_pointer__what)
 Generated constructor for class ss_pointer.
virtual void gc_mark ()
 Marking routine for class ss_pointer.

Private Attributes

srp< ss_typewhat

Static Private Attributes

static ptr< ::lestes::std::map<
srp< ss_type >, srp< ss_type > > > 
the_instances = ::lestes::std::map< srp< ss_type >, srp< ss_type > > ::create()
 holder for the class instances
static ptr< reflection_listreflection = reflection

Detailed Description

Class for pointered types.

Singleton class.

Definition at line 498 of file ss_type.g.hh.


Constructor & Destructor Documentation

lestes::lang::cplus::sem::ss_pointer::ss_pointer ( ptr< ss_type a__ss_pointer__what  )  [protected]

Generated constructor for class ss_pointer.

Generated constructor for class ss_pointer.

Author:
lsg

Definition at line 650 of file ss_type.g.cc.

Referenced by create().

00651         : ss_type(), what(checked(a__ss_pointer__what))
00652 {}


Member Function Documentation

ptr< ss_type > lestes::lang::cplus::sem::ss_pointer::what_get (  )  const

The method what_get returns the value of the field ss_pointer::what.

Returns:
The value of ss_pointer::what.
Author:
lsg

Definition at line 603 of file ss_type.g.cc.

References what.

00604 {
00605         return what;
00606 }

void lestes::lang::cplus::sem::ss_pointer::what_set ( const ptr< ss_type > &  x  ) 

The method what_set sets the field ss_pointer::what to the given value.

Parameters:
[in] x The new value to set ss_pointer::what to.
Author:
lsg

Definition at line 612 of file ss_type.g.cc.

References what.

00613 {
00614         ss_pointer::what = x;
00615 }

ptr< ss_type > lestes::lang::cplus::sem::ss_pointer::instance ( ptr< ss_type x  )  [static]

get the instance representing pointer to the argument type

Returns type representing pointer to a given type.

Precondition:
x != NULL
Parameters:
x The type to make pointer to.
Returns:
The pointer type to the given type.

Definition at line 210 of file ss_type.cc.

References lestes::intercode::intercode::create(), lassert, and the_instances.

Referenced by lestes::lang::cplus::sem::or_builtin_operator_declaration_creator::add_bool_ptr_ptr(), lestes::lang::cplus::sem::or_builtin_operator_declaration_creator::add_int_ptr_ptr(), lestes::lang::cplus::sem::or_builtin_operator_declaration_creator::add_ptr_int_ptr(), lestes::lang::cplus::sem::or_builtin_operator_declaration_creator::add_ptr_ptr(), lestes::lang::cplus::sem::or_builtin_operator_declaration_creator::add_ptr_ptr_int(), lestes::lang::cplus::sem::or_builtin_operator_declaration_creator::add_ref_ptr(), lestes::lang::cplus::sem::or_builtin_operator_declaration_creator::add_ref_ptr_const(), lestes::lang::cplus::sem::or_builtin_operator_declaration_creator::add_vq_ptr_nonref_vq_ptr_ref_int(), lestes::lang::cplus::sem::or_builtin_operator_declaration_creator::add_vq_ptr_ref_vq_ptr_ref(), lestes::lang::cplus::sem::or_builtin_operator_declaration_creator::add_vq_ptr_ref_vq_ptr_ref_int(), lestes::lang::cplus::sem::or_builtin_operator_declaration_creator::add_vq_ptr_ref_vq_ptr_ref_ptr(), lestes::lang::cplus::sem::ss_expr2pi::visit_ss_assign(), lestes::lang::cplus::sem::ss_expr2pi::visit_ss_get(), and lestes::lang::cplus::sem::ss_expr2pi::visit_ss_vol_get().

00211 {
00212         the_instances->dump_barrier_set(true); // XXX: needed just once :-I
00213 
00214         lassert(x);
00215         srp < ss_type > &result = (*the_instances)[x];
00216 
00217         if (result) 
00218                 return result;
00219 
00220         return result = ss_pointer::create(x);
00221 }

ptr<::lestes::std::list< srp< or_ics_functional > > > lestes::lang::cplus::sem::ss_pointer::accept_or_ics_base ( ptr< or_ics_base v  )  [virtual]

Implements lestes::lang::cplus::sem::ss_type.

Definition at line 617 of file ss_type.g.cc.

00618 {
00619         return v->visit_ss_pointer( this );
00620 }

or_cv_enum lestes::lang::cplus::sem::ss_pointer::accept_or_ics_base_cv ( ptr< or_ics_base_cv v  )  [virtual]

Implements lestes::lang::cplus::sem::ss_type.

Definition at line 622 of file ss_type.g.cc.

00623 {
00624         return v->visit_ss_pointer( this );
00625 }

ptr<::lestes::md::types::tm_data_type_base > lestes::lang::cplus::sem::ss_pointer::accept_ss_type2tm_type_gen_base ( ptr< ss_type2tm_type_gen_base v  )  [virtual]

Implements lestes::lang::cplus::sem::ss_type.

Definition at line 627 of file ss_type.g.cc.

00628 {
00629         return v->visit_ss_pointer( this );
00630 }

void lestes::lang::cplus::sem::ss_pointer::accept_ss_type_visitor ( ptr< ss_type_visitor v  )  [virtual]

Implements lestes::lang::cplus::sem::ss_type.

Definition at line 632 of file ss_type.g.cc.

00633 {
00634         return v->visit_ss_pointer( this );
00635 }

ptr< ss_pointer > lestes::lang::cplus::sem::ss_pointer::create ( ptr< ss_type a__ss_pointer__what  )  [static]

First generated factory method for class ss_pointer.

This factory method for class ss_pointer takes values of all fields as arguments.

Author:
lsg

Definition at line 641 of file ss_type.g.cc.

References ss_pointer().

00642 {
00643         return ptr< ss_pointer > ( new ss_pointer(a__ss_pointer__what) );
00644 }

ptr< object::reflection_list > lestes::lang::cplus::sem::ss_pointer::reflection_get (  )  const [virtual]

for purposes of dumping

Reimplemented from lestes::lang::cplus::sem::ss_type.

Definition at line 654 of file ss_type.g.cc.

References lestes::std::list< T >::create(), reflection, and lestes::lang::cplus::sem::ss_type::reflection_get().

00655 {
00656         if (!reflection) {
00657                 typedef class_reflection::field_metadata md;
00658                 typedef class_reflection::field_metadata_list mdlist;
00659                 ptr<mdlist> mdl = mdlist::create();
00660                 mdl->push_back( md::create( "what", "ss_type" ) );
00661                 mdl->push_back( md::create( "the_instances", "map&lt; srp&lt; ss_type &gt;, srp&lt; ss_type &gt; &gt;" ) );
00662                 reflection = reflection_list::create( ss_type::reflection_get() );
00663                 reflection->push_back( class_reflection::create( "ss_pointer", mdl ) );
00664         }
00665         return reflection;
00666 }

ptr< object::field_list_list > lestes::lang::cplus::sem::ss_pointer::field_values_get (  )  const [virtual]

for purposes of dumping

Reimplemented from lestes::lang::cplus::sem::ss_type.

Definition at line 668 of file ss_type.g.cc.

References lestes::std::list< T >::create(), and lestes::lang::cplus::sem::ss_type::field_values_get().

00669 {
00670         ptr < field_list_list > result = ss_type::field_values_get();
00671         result->push_back( value_list::create() );
00672         result->back()->push_back( this->what );
00673         result->push_back( value_list::create() );
00674         result->back()->push_back( this->the_instances );
00675         return result;
00676 }

void lestes::lang::cplus::sem::ss_pointer::gc_mark ( void   )  [protected, virtual]

Marking routine for class ss_pointer.

Marking routine is used for garbage collection.

Author:
lsg

Reimplemented from lestes::lang::cplus::sem::ss_type.

Definition at line 683 of file ss_type.g.cc.

References lestes::lang::cplus::sem::ss_type::gc_mark().

00684 {
00685         ss_type::gc_mark();
00686 }


Member Data Documentation

srp< ss_type > lestes::lang::cplus::sem::ss_pointer::what [private]

Definition at line 534 of file ss_type.g.hh.

Referenced by what_get(), and what_set().

ptr<::lestes::std::map< srp< ss_type >, srp< ss_type > > > lestes::lang::cplus::sem::ss_pointer::the_instances = ::lestes::std::map< srp< ss_type >, srp< ss_type > > ::create() [static, private]

holder for the class instances

Definition at line 536 of file ss_type.g.hh.

Referenced by instance().

ptr< object::reflection_list > lestes::lang::cplus::sem::ss_pointer::reflection = reflection [static, private]

Reimplemented from lestes::lang::cplus::sem::ss_type.

Definition at line 537 of file ss_type.g.hh.

Referenced by reflection_get().


The documentation for this class was generated from the following files:
Generated on Mon Feb 12 18:25:30 2007 for lestes by doxygen 1.5.1-20070107