Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

more::lang::ct_struct Class Reference

The layout of a store which is of ct_struct type. More...

#include <more/lang/ct_struct.h>

Inheritance diagram for more::lang::ct_struct:

Inheritance graph
[legend]
Collaboration diagram for more::lang::ct_struct:

Collaboration graph
[legend]
List of all members.

Public Types

Public Methods


Detailed Description

The layout of a store which is of ct_struct type.

Classes are built on top of this.


Member Typedef Documentation

typedef container::const_iterator more::lang::ct_struct::member_const_iterator
 

A bidirectionaly iterator over the range of const members.

typedef container::iterator more::lang::ct_struct::member_iterator
 

A bidirectionaly iterator over the range of members.

typedef std::size_t more::lang::ct_struct::size_type
 

Reimplemented from more::lang::ct_type.


Constructor & Destructor Documentation

more::lang::ct_struct::ct_struct char const *    c_name = 0 [explicit]
 

Construct a new struct.

Do not provide a name for types to be defined in a package.

virtual more::lang::ct_struct::~ct_struct   [virtual]
 


Member Function Documentation

member_iterator more::lang::ct_struct::append ct_type const *    t [inline]
 

Append an anonymous member to the structure.

member_iterator more::lang::ct_struct::append ct_type const *   ,
char const *   
 

Append a named member to the structure.

member_iterator more::lang::ct_struct::append_inherited ct_type const *    t
 

Append an inherited type to the structure. This inheritance is not layout compatible with C++.

identifier more::lang::ct_struct::c_name   const [inline]
 

The C identifier of this type.

virtual ct_struct* more::lang::ct_struct::clone   const [virtual]
 

Return a clone of structure description.

Reimplemented from more::lang::ct_type.

virtual void more::lang::ct_struct::construct_copy void *    p,
void *    src
const [virtual]
 

Constructor the object at p as a copy of src.

Reimplemented from more::lang::ct_type.

virtual void more::lang::ct_struct::destruct void *    p const [virtual]
 

Destruct the object at p.

Reimplemented from more::lang::ct_type.

virtual bool more::lang::ct_struct::equal void *    p0,
void *    p1
const [virtual]
 

True iff the objects at p0 and p1 are equal.

Reimplemented from more::lang::ct_type.

virtual bool more::lang::ct_struct::equal_to ct_type const *    const [virtual]
 

Reimplemented from more::lang::ct_type.

std::pair<ct_struct const*, member const*> more::lang::ct_struct::find_inherited_rec ct_type const *    t const
 

Find an inherited type t as any subtype of this.

If such a type is fond, return the ct_struct which contains it and its member descriptor. If the type is ambiguous, return the uppermost ct_struct which contain all occurances of t, and 0 for the member descriptor. If there is no such subtype, return zero for both the structure and member descriptor.

Precondition:
this and t are not the same.

void more::lang::ct_struct::freeze   [inline]
 

Inform that the description is completed.

virtual void more::lang::ct_struct::hash hash_type   const [virtual]
 

Reimplemented from more::lang::ct_type.

bool more::lang::ct_struct::is_frozen   const [inline]
 

True if freeze() was called.

bool more::lang::ct_struct::is_optimized   const [inline]
 

member_const_iterator more::lang::ct_struct::member_begin   const [inline]
 

member_iterator more::lang::ct_struct::member_begin   [inline]
 

The range over members, including inheritance members.

size_type more::lang::ct_struct::member_count   const [inline]
 

The number of members, including inheritance members.

member_const_iterator more::lang::ct_struct::member_end   const [inline]
 

member_iterator more::lang::ct_struct::member_end   [inline]
 

virtual void more::lang::ct_struct::print_declaration_post std::ostream &   ,
printopt_type   
const [virtual]
 

Print the part of the declaration which succeeds the variable or function name.

Reimplemented from more::lang::ct_type.

virtual void more::lang::ct_struct::print_declaration_pre std::ostream &   ,
printopt_type   
const [virtual]
 

Print the part of the declaration which precedes the variable or function name.

Reimplemented from more::lang::ct_type.

void more::lang::ct_struct::print_definition std::ostream &   ,
printopt_type    = 0
const
 

Prints the definition as C/C++ source code.

For C print_forward must also be called before print_definition to create a valid source file. For both languages it is a good idea to print all forward declarations first in case a structure contains a pointer to a type defined after its definition.

void more::lang::ct_struct::print_forward std::ostream &   ,
printopt_type    = 0
const
 

Prints a forward declaration as C/C++ source code.

void* more::lang::ct_struct::proj void *    ptr,
ct_type const *    t
const
 

Project ptr of pointer to this type to a pointer to inherited type t.

Return 0 if t is not an inherited type.

void more::lang::ct_struct::set_c_name identifier    id [inline]
 

Set the C identifier for this type.


The documentation for this class was generated from the following file:
Generated on Sat Sep 7 19:12:48 2002 for more with Doxygen 1.2.13.1. Doxygen 1.2.13.1 is written and copyright 1997-2002 by Dimitri van Heesch.