if (printWriter != null) {
try {
JClassType type = typeOracle.getType(typeName);
GwtRpcSerialTypes annotation = type.getAnnotation(GwtRpcSerialTypes.class);
if (annotation == null) {
logger.log(TreeLogger.ERROR, "No SerialTypes annotation on CometSerializer type: " + typeName);
throw new UnableToCompleteException();
}
SerializableTypeOracleBuilder typesSentToBrowserBuilder = new SerializableTypeOracleBuilder(logger, context);
SerializableTypeOracleBuilder typesSentFromBrowserBuilder = new SerializableTypeOracleBuilder(logger, context);
List<Class<?>> serializableTypes = new ArrayList();
Collections.addAll(serializableTypes, annotation.value());
for (Class<?> serializable : serializableTypes) {
int rank = 0;
if (serializable.isArray()) {
while (serializable.isArray()) {
serializable = (Class<?>) serializable.getComponentType();