writeExpression method
Implementation
String writeExpression([String? source]) {
source ??= 'this.${name}';
switch (this.typeNode.toRawType().toLowerCase()) {
case 'float':
return 'GraphClientConfig.doubleOf($source)';
case 'double':
return 'GraphClientConfig.doubleOf($source)';
case 'int':
return 'GraphClientConfig.intOf($source)';
case 'string':
case 'boolean':
case 'id':
return source;
default:
return 'GraphClientConfig.write($source, typeName: "${typeNode.toDartType(withNullability: false)}", isList: ${isList})';
}
}