CsStruct Struct Reference

Struct AST node. More...

Inheritance diagram for CsStruct:

CsClassStruct CsScopeNode CsNode List of all members.

Public Member Functions

 CsStruct ()
 CsStruct (LineInfo line_info)
virtual void addTokensRecursive (CsTokenCollector &tokenCollector)
 Recusively collect token indexes in source code order.
virtual void addTokens (CsTokenCollector &tokenCollector)
 Collect token indexes associated with this AST node.
virtual void clearEntities ()
 Clear all entity references (for internal purpose only).

Public Attributes

CsTokenIndex struct_token
CsTokenIndex identifier_token
CsTokenIndex lcurly_token
CsTokenIndex rcurly_token
CsTokenIndex semicolon_token

Detailed Description

Struct AST node.

EBNF grammar:

struct-declaration:
  (attributes)? (struct-modifiers)? "struct" identifier (type-base)? struct-body (";")?

struct-modifiers:
  (struct-modifier)+

struct-modifier:
  "public"
  "protected"
  "internal"
  "private"
  "extern"

struct-body:
  "{" (struct-member-declarations)? "}"

struct-member-declarations:
  (struct-member-declaration)+

struct-member-declaration:
  constant-declaration
  field-declaration
  method-declaration
  property-declaration
  event-declaration
  indexer-declaration
  operator-declaration
  constructor-declaration
  destructor-declaration
  static-constructor-declaration
  type-declaration


Constructor & Destructor Documentation

CsStruct::CsStruct  )  [inline]
 

CsStruct::CsStruct LineInfo  line_info  )  [inline, explicit]
 


Member Function Documentation

virtual void CsStruct::addTokens CsTokenCollector tokenCollector  )  [virtual]
 

Collect token indexes associated with this AST node.

Implements CsNode.

virtual void CsStruct::addTokensRecursive CsTokenCollector tokenCollector  )  [virtual]
 

Recusively collect token indexes in source code order.

Implements CsNode.

virtual void CsStruct::clearEntities  )  [virtual]
 

Clear all entity references (for internal purpose only).

Reimplemented from CsClassStruct.


Member Data Documentation

CsTokenIndex CsStruct::identifier_token
 

CsTokenIndex CsStruct::lcurly_token
 

CsTokenIndex CsStruct::rcurly_token
 

CsTokenIndex CsStruct::semicolon_token
 

CsTokenIndex CsStruct::struct_token
 

© 2005 metaspec