/*----------------------------------------------------------------------------
Copyright (c)2000 TogetherSoft LLC. Patents pending. All rights reserved.
----------------------------------------------------------------------------*/
package com.togethersoft.modules.genidl;
import java.util.Hashtable;
/** The storage of IDL keywords. */
abstract class IdlKeywords {
public static boolean isKeyword(String kw) {
return htKeywords.containsKey(kw);
}
private final static String[] idlKeywords = {
"any",
"double",
"interface",
"readonly",
"unsigned",
"attribute",
"enum",
"long",
"sequence",
"union",
"boolean",
"exception",
"module",
"short",
"void",
"case",
"FALSE",
"Object",
"string",
"wchar",
"char",
"fixed",
"octet",
"struct",
"wstring",
"const",
"float",
"oneway",
"switch",
"context",
"in",
"out",
"TRUE",
"default",
"inout",
"raises",
"typedef"};
private final static Hashtable htKeywords;
static {
int idlKeywordsLength = idlKeywords.length;
htKeywords = new Hashtable(idlKeywordsLength);
for (int i = 0; i < idlKeywordsLength; i++) {
htKeywords.put(idlKeywords[i], idlKeywords[i]);
}
}
}
|