Five stars Perplexity good job. Make sure to submit it on the competition thread.
|
C#
Polymorphism in C# [Object-oriented Programming] |
(Feb 1, 2013 04:40 PM)tweety Wrote: Now Skid's can shut up about Polymorphic hax and learn what it actually means in OOP. Rated 5. People are still using the proper definition, they're just referring to Polymorphic Encryptions. (Feb 1, 2013 04:45 PM)pr3fix Wrote: Pretty basic, yet I believe that it will be useful to beginners. Good job :) Translation: I'm really good at C# and I want you all to know that I already know how to do this. Thanks for the tutorial OP. (Feb 1, 2013 04:54 PM)Koolg223 Wrote: Translation: I'm really good at C# and I want you all to know that I already know how to do this. This is one of the most basic things someone should learn. If you don't know how to do this and you say you can code in C#, then there is something wrong with you. (Feb 1, 2013 05:02 PM)Occulta Wrote: This is one of the most basic things someone should learn. If you don't know how to do this and you say you can code in C#, then there is something wrong with you. And you've missed the point entirely... Also, you're wrong, there are many far more basic things. If you polled this forum, I'm guessing at least 50% of people here don't know how to use it. (Feb 1, 2013 04:54 PM)Koolg223 Wrote: Translation: I'm really good at C# and I want you all to know that I already know how to do this. No, he's just speaking truthfully. A form of anonymous type/methods; this is not new (every obfuscatord does this), isn't poly or even close, and provides no purpose as it's not explaining the reason why the framework has anon methods/types in the first place, nor what type casting is. There is a much greater purpose for this in OOP, than just theoretical guessing of "polymorphism". In the end, you've given them a great tool for the wrong job, and didn't explain what the tool is for, only what it does. .NET being a translated language run in a virtual machine, with the highest degree of late-binding of any langauge/framework, has much better avenues to explore for poly than most other languages. Think of this way; 1. Anything, and everything can be called via a string in .net with reflection besides datatypes.. And I mean everything besides the 2-3 methods needed to reflect (and there are workarounds even for that) 2. A virtual machine (CLR) just translates code of the executable. But what happens if you can change that translation from within the virtualmachine? You can then change classes, methods, datatypes... Lets say I want to call "Console.Read", we can change that to "Microsoft.Sucks". Anything can have is translation changed, thereby leaving room for almost every bit in the executable to be dynamic... If you know how to inject msil already, it's a fairly straight forward process of hijacking the methods you want to change by injecting code into their libraries (dll's inside .net folder or memory) and changing their names. True examples of poly in languages like c, show use of their own custom virtualmachine, yet .net has the best vm already made and it's easily modifiable with little a little skill. Mono is an example of a modified CLR. (Mar 15, 2013 08:29 PM)TxTriton Wrote: You're still typcasting there lol. I know, what I meant was that you wouldn't need to manual type cast. |
|
|
