I'd like to give my Java sources to another Java developer so that he can study them while he should be unable to compile them. I am looking for a simple but effective one-way algorithm making my sources uncompilable. I hope I explained the goal clearly.
My first idea was parsing all my sources and making all my method names random mixed case:
private double getAvailableCash() --> private double gEtaVailabLEcASh()
It is quite simple and not so easy to redo, not impossible though. Can you suggest me some other, hopefully better ways?
Update:
Many of you commented/asked about the reason that someone would like to do this. Suppose the following scenario: you have to prove that you are ready with a good quality solution before the other developer pays you, but you do not trust him for a good reason. Showing a working compiled demo is not enough because he wants to see the way you worked. If you gave him the compilable source it is possible that you would not get your payment as soon as you would without giving the source..
Anyway, it seemed a very interesting, funny problem to me and seeing the many comments and answers even for many of you.. :-)