You need to create a script (in any language, I'm a dev myself) that would:
1. Lexically parse .cs file. (C# code) - use some existing tool
2. Match every expression:
2.1 FUNCTIONNAME(arg1, arg2)
2.2 FUNCTIONNAME(arg1, arg2, arg3)
2.3 ARRAY2d[arg1, arg2)
3. Get args as strings (if needed for #4)
4. Fully replace the matched expression with the result of user-defined function.
5. Output the new file to stdout
Pseudo-code:
// I will define this function myself
transformContent(arg1, arg2):
return arg1 + ' * ' + arg2;
parsedFile = parseFile('filename')
for every expression in parsedFile:
if expression is a Function with 2 args:
newExpression = transformContent(expression.arg1, expression.arg2)
expression.remove()
newExpression.insert()
You can use any major programming language - Windows or Linux. I just need a script, no need to check user input etc.
About the recuiterMember since Sep 16, 2017 Tom Ward
from England, United Kingdom