org.jacorb.idl

Class TypeDeclaration

Known Direct Subclasses:
EnumType, Interface, NativeType, StructType, TypeDef, UnionType, Value

public class TypeDeclaration
extends Declaration

Version:
$Id: TypeDeclaration.java,v 1.24 2004/05/06 12:39:59 nicolas Exp $

Author:
Gerald Brose

Field Summary

TypeDeclaration
type_decl

Fields inherited from class org.jacorb.idl.IdlSymbol

_id, enclosing_symbol, fileSeparator, included, inhibitionFlag, is_pseudo, omg_package_prefix, pack_name

Fields inherited from class org.jacorb.idl.runtime.symbol

parse_state, sym

Constructor Summary

TypeDeclaration(int num)
class constructor

Method Summary

void
accept(IDLTreeVisitor visitor)
let the visitor pattern do its work...
boolean
basic()
Object
clone()
TypeDeclaration
declaration()
String
getIDLTypeName()
get this symbol's IDL type name
String
getJavaTypeName()
get this types's mapped Java name
String
getRecursiveTypeCodeExpression()
String
getTypeCodeExpression()
String
getTypeCodeExpression(Set knownTypes)
Returns a type code expression (for use in generated code) for this type.
String
holderName()
void
markTypeDefd(String alias)
we have to be able to distinguish between explicitly typedef'd type names and anonymously defined type names
void
parse()
empty parse
void
print(PrintWriter ps)
String
printReadExpression(String streamname)
String
printReadStatement(String var_name, String streamname)
String
printWriteStatement(String var_name, String streamname)
void
setEnclosingSymbol(IdlSymbol s)
void
setPackage(String s)
void
set_included(boolean i)
used by the lexer to mark this symbol as included from another IDL file
String
toString()
String
typeName()

Methods inherited from class org.jacorb.idl.Declaration

accept

Methods inherited from class org.jacorb.idl.IdlSymbol

accept, addImportedAlias, addImportedName, addImportedName, addImportedNameHolder, deEscapeName, escapeName, generateIncluded, getEnclosingSymbol, get_token, id, isEscaped, is_included, is_pseudo, name, new_num, omgPrefix, parse, print, printIdMethod, printImport, setEnclosingSymbol, setPackage, setPrintPhaseNames, set_name, set_pseudo, set_token

Field Details

type_decl

public TypeDeclaration type_decl

Constructor Details

TypeDeclaration

public TypeDeclaration(int num)
class constructor

Method Details

accept

public void accept(IDLTreeVisitor visitor)
let the visitor pattern do its work...
Overrides:
accept in interface Declaration


basic

public boolean basic()


clone

public Object clone()


declaration

public TypeDeclaration declaration()


getIDLTypeName

public String getIDLTypeName()
get this symbol's IDL type name


getJavaTypeName

public String getJavaTypeName()
get this types's mapped Java name


getRecursiveTypeCodeExpression

public String getRecursiveTypeCodeExpression()


getTypeCodeExpression

public String getTypeCodeExpression()

Returns:
a string for an expression of type TypeCode that describes this type


getTypeCodeExpression

public String getTypeCodeExpression(Set knownTypes)
Returns a type code expression (for use in generated code) for this type. If `knownTypes' contains this type, then a recursive type code is returned.


holderName

public String holderName()


markTypeDefd

public void markTypeDefd(String alias)
we have to be able to distinguish between explicitly typedef'd type names and anonymously defined type names


parse

public void parse()
empty parse
Overrides:
parse in interface IdlSymbol


print

public void print(PrintWriter ps)
Overrides:
print in interface IdlSymbol


printReadExpression

public String printReadExpression(String streamname)


printReadStatement

public String printReadStatement(String var_name,
                                 String streamname)


printWriteStatement

public String printWriteStatement(String var_name,
                                  String streamname)


setEnclosingSymbol

public void setEnclosingSymbol(IdlSymbol s)
Overrides:
setEnclosingSymbol in interface IdlSymbol


setPackage

public void setPackage(String s)
Overrides:
setPackage in interface IdlSymbol


set_included

public void set_included(boolean i)
used by the lexer to mark this symbol as included from another IDL file


toString

public String toString()


typeName

public String typeName()