In a Java/Spring/C# project, I intend to have a list of returncodes which shall be available at both sides: Java and C#. First guess was to have a file which is available in both worlds and defines constants:
private static final int RC_NO_ERROR = 0;
Unfortunately, final
is not known to C#, and the C# equivalents const
, sealed
and readonly
are not known to Java. Is there any easy way like a preprocessor which helps with that? Can I "define" the keyword final
to be at least tolerated if not recognized as const
and friends?
My plan b woud be to let sed/awk do the job but I would prefer a solution which does not involve a tool chain step.