bool isPrimitiveTypeName(String typeName) { switch (typeName) { case 'bool': case 'int': case 'num': case 'double': case 'String': return true; } return false; }