p4ulor / AVE

Content for the college subject Virtual Execution Environments. Covers reflection, meta programming with IL, metadata, custom attributes, etc, using C# (and dotnet). Done in the summer of 2021

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Understanding virtual execution environments using C#

Homeworks and class exercises from the discipline Virtual Execution Environments

TPC list Exercises 1 2 and 3 about reflection Lesson 38 exercise about reflection, interfaces and delegates

This discipline covers the following subjects and questions:

  • What is a computational/software environment AKA virtual execution environments AKA software framework
  • The problems that Virtual execution environments solve
  • What is an assembly and how to get a representation of a type or component(a .dll) and exploring it
  • IL(intermediate language) + metadata = (software) component
  • What is metadata for?
  • The reflection API, which when in effect(in pratice) it's called introspection(which uses metadata)
  • Creating our own metadata with custom attributes
  • Programming in IL
  • Understanding what types(reference types and value types) are how they are used during the execution of a program
  • Sequences and Delegates
  • Generics

How to navigate and open the projects

Each folder that has the .vscode folder should be opened as a project

Open the folder and type in the explorer address bar: cmd

In the console, write: code .

Or just drag and release the folder into VSC and it will open the project

Inside each folder that contains a .csproj file for the project. Run this command in console:

  • dotnet build

Which will compile(AKA build) the .dll files and other stuff which, are files of larger size and shouldn't be placed in repos.


Create projects using:

dotnet new operation -o FolderName

Example of operations used:

  • console (creates project with main method)
  • classlib (creates project intended to just contain utility classes, no main method)
  • xunit (creates project intended to run tests on)

IDE used: VSC. It's fast, simple and very good.

Extensions recommended for this repo using VSC:


Extra program installed: ildasm.exe

It's used to consult metadata and the IL code of .dll files.

About

Content for the college subject Virtual Execution Environments. Covers reflection, meta programming with IL, metadata, custom attributes, etc, using C# (and dotnet). Done in the summer of 2021


Languages

Language:C# 99.5%Language:Batchfile 0.5%