Join Ted Neward for an in-depth discussion in this video Invoking methods demo, part of CLR Reflection for Developers.
- [Instructor] So now, in this particular case,…what I'm going to do is I'm going to want to actually…invoke the distance method reflectively,…which means I'm going to need another point, by the way,…because it's hard to calculate…the distance between two points…if you don't have two points,…so let's calculate the distance between…the points at 12, 12 and the points at 12, 13.…That should actually be a fairly…straightforward calculation.…Now that we have a second point,…and let's make sure that we print that, construct it out.…Let's take this one out, just so we're not…dealing with too much noise there.…
That way we'll have some verification…that we're in fact working with the correct points.…Now, in order to do this method invocation,…same kind of thing as what we saw before.…We're going to grab the distance method…by going to the point type, and we're going to say,…I'm going to get ahold of this method, and again,…if it's completely unambiguous to grab a method by name,…we can do so, which I will do so here,…
- Working with the IL Disassembler (Ildasm)
- Namespaces and types
- Type API
- Properties API
- MethodBase and MethodInfo API
- Constructors API
- Fields API
- Constructing objects
- Accessing properties and fields
- Invoking methods
Skill Level Intermediate
Deploying .NET Applications with Octopus Deploywith Floyd Hilton1h 27m Intermediate
2. IL Disassembler (Ildasm)
3. Reflection Namespace and Types
4. Type API
5. Properties API
6. MethodBase and MethodInfo API
7. Constructors API
Constructors API demo2m 52s
8. Fields API
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.