"{ Package: 'cvut:fel/cface' }"
"{ NameSpace: Cface }"
Object subclass:#CNodeVisitor
instanceVariableNames:''
classVariableNames:''
poolDictionaries:''
category:'Cface-Visitors'
!
!CNodeVisitor class methodsFor:'instance creation'!
new
^ self basicNew initialize.
"Created: / 12-02-2008 / 22:55:07 / janfrog"
! !
!CNodeVisitor class methodsFor:'processing'!
process: aCNode
^self new process: aCNode
"Created: / 12-02-2008 / 23:49:23 / janfrog"
! !
!CNodeVisitor methodsFor:'initialization'!
initialize
"Invoked when a new instance is created."
"/ please change as required (and remove this comment)
"/ super initialize. -- commented since inherited method does nothing
"Created: / 12-02-2008 / 22:55:07 / janfrog"
! !
!CNodeVisitor methodsFor:'processing'!
process: aCNode
self visit: aCNode
"Created: / 12-02-2008 / 23:46:49 / janfrog"
! !
!CNodeVisitor methodsFor:'visiting'!
visit: aCNode
^aCNode acceptVisitor: self
"Created: / 08-02-2008 / 09:06:17 / janfrog"
!
visitCArgumentNode:anObject
^self visit: anObject type
"Created: / 12-02-2008 / 22:14:55 / janfrog"
!
visitCArrayNode:anObject
^self visit: anObject type
"Created: / 12-02-2008 / 22:14:55 / janfrog"
!
visitCCharNode:anObject
"Created: / 12-02-2008 / 22:14:55 / janfrog"
!
visitCConstNode:anObject
self visit: anObject type
"Created: / 12-02-2008 / 22:14:55 / janfrog"
!
visitCDefinitionFileNode:anObject
anObject definitions do:
[:definition|self visit: definition]
"Created: / 12-02-2008 / 22:14:55 / janfrog"
!
visitCDoubleNode:anObject
"Modified: / 12-02-2008 / 23:04:50 / janfrog"
!
visitCEnumNode:anObject
anObject values do:
[:enumValue|self visit: enumValue]
"Created: / 12-02-2008 / 22:14:55 / janfrog"
!
visitCEnumValueNode:anObject
"Created: / 12-02-2008 / 22:14:55 / janfrog"
!
visitCFloatNode:anObject
"Created: / 12-02-2008 / 22:14:55 / janfrog"
!
visitCFunctionNode:anObject
anObject arguments do:
[:argumentNode|self visit: argumentNode].
self visit: anObject return
"Created: / 12-02-2008 / 22:14:55 / janfrog"
!
visitCFunctionTypeNode:anObject
anObject arguments do:
[:argumentNode|self visit: argumentNode].
self visit: anObject return
"Created: / 17-02-2008 / 18:44:19 / janfrog"
!
visitCIntNode:anObject
"Created: / 12-02-2008 / 22:14:55 / janfrog"
!
visitCLongNode:anObject
self visit: anObject type
"Created: / 12-02-2008 / 22:14:55 / janfrog"
!
visitCPointerNode:anObject
self visit: anObject type
"Created: / 12-02-2008 / 22:14:55 / janfrog"
!
visitCShortNode:anObject
"Created: / 12-02-2008 / 23:19:46 / janfrog"
!
visitCStructFieldNode:anObject
self visit: anObject type
"Created: / 12-02-2008 / 22:14:55 / janfrog"
!
visitCStructNode:anObject
anObject fields do:
[:fieldNode|self visit: fieldNode]
"Created: / 12-02-2008 / 22:14:55 / janfrog"
!
visitCTypedefNode:anObject
self visit: anObject type
"Created: / 12-02-2008 / 22:14:55 / janfrog"
!
visitCUnionNode:anObject
anObject fields do:
[:fieldNode|self visit: fieldNode]
"Created: / 12-02-2008 / 22:14:55 / janfrog"
!
visitCUnknownTypeNode:anObject
"Created: / 12-02-2008 / 22:14:55 / janfrog"
!
visitCUnsignedNode:anObject
self visit: anObject type
"Created: / 12-02-2008 / 23:00:26 / janfrog"
!
visitCUserDefinedTypeNode:anObject
"Created: / 12-02-2008 / 23:00:03 / janfrog"
!
visitCVoidNode:anObject
"Created: / 12-02-2008 / 22:14:55 / janfrog"
!
visitObject:anObject
"dispatched back from the visited objects (visitor pattern)"
"general fallBack - please change as required"
self halt:'not yet implemented'
"Created: / 12-02-2008 / 23:19:46 / janfrog"
! !
!CNodeVisitor class methodsFor:'documentation'!
version
^ '$Header: /opt/data/cvs/cvut-fel/cface/Cface__CNodeVisitor.st,v 1.1 2008/02/26 15:57:32 vranyj1 Exp $'
! !