Questions tagged [fody]

Extensible tool for weaving .net assemblies

Extensible tool for weaving .NET assemblies

Uses Mono.Cecil and an add-in based approach to modifying the IL of .net assemblies at compile time.

  • No install required to build
  • No attributes required
  • No references required
  • Supports .NET 3.5, .NET 4, .NET 4.5, Silverlight 3, Silverlight 4, Silverlight 5, Windows Phone 7 and .NET Metro on Windows 8, MonoTouch, MonoDroid, Mono
  • Supports client profile mode

Links:

181 questions
0
votes
0 answers

Compile Time Creation Process of Dto Classes

How can I ensure that the Dto classes that I will use instead of the existing entity classes in my project are automatically generated after compilation using the Fody library ? I found out that the Fody Library in Nuget can generate code in the…
0
votes
1 answer

PropertyChanged Fody accesses ObservableCollection

Is it possible to instruct Fody to generate PropertyChanged Events for the Properties Color1 and Color2 if the corresponding Items in the ObservableCollection _colors are changing? public class MyModel : INotifyPropertyChanged { public event…
AndiR
  • 179
  • 10
0
votes
0 answers

Virtuosity.Fody and Unity project?

I'm trying to use Virtuosity.Fody in a Unity project and I've followed the steps to install it, but it's not actually doing any weaving. The unit tests that depend on virtual methods fail if I remove the keyword, which Virtuosity should be adding...
AX2
  • 135
  • 12
0
votes
1 answer

How Blazor Server AOP logging?

I would like to implement and use an AOP logging in my Blazor Server .NET 5 (C# 9) application, for generic enter-exit-exception scenarios for the marked method(s). I know how to do it with MethodBoundaryAspect.Fody NuGet package and a custom…
Tomcat
  • 38
  • 4
0
votes
0 answers

Modify IL during compilation: Workaround for declaring a constant custom struct

I'm writing a library for ternary computing, based on Trits instead of Bits. Trits can have three values. Sometimes represented as 0,1 and 2, sometimes as -1, 0 and 1. I've called them Down, Middle and Up. In some scenario's, it's useful to have…
realbart
  • 3,497
  • 1
  • 25
  • 37
0
votes
0 answers

Using a locally defined class instead of the one provided by a library/package C# IL Weaving

I have seen stuff like Fody and in fact have been using PropertyChanged which reduces the boilerplate code after implementing the INotifyPropertyChanged interface. I believe it is done by 'weaving the IL' so an idea crossed my mind. The problem is…
0
votes
1 answer

WFP View not updating when object properties change with INotifyPropertyChanged implemented via Fody

I've looked everywhere and can't seem to find a solution to this. The object/class that I have bound to a WPF form shows the object properties fine on the first creation of the object. Now however, if I change any of the properties in the object,…
0
votes
1 answer

ReactiveUI Fody [Reactive] attribute not working in Xamarin Forms

I've tried following the documentation for ReactiveUI.Fody. https://github.com/kswoll/ReactiveUI.Fody Added the FodyWeavers.xml the generated file to the shared project.
Sach K
  • 591
  • 4
  • 20
0
votes
0 answers

Error during building application with Fody and Costura via VS 2019 : Binary is being used by another process

I have a C# Console application that was developed in different machines. In this application, we chose to use Fody, because it's the only thing we found that would embed all external resource dependencies (any extra class libraries) into a single…
Lalindu
  • 329
  • 3
  • 17
0
votes
0 answers

How to disable separate Fody plugin in Release mode?

I'm using MethodDecorator.Fody (for injecting debug stuff) and some other plugins (PropertyChaged etc.). Is there any way to disable MethodDecorator.Fody in Release build mode but keep the others enabled?
0
votes
2 answers

Fody and Assembly.GetExecutingAssembly().Location returns empty string

I was calling Assembly.GetExecutingAssembly().Location in one of the dlls of a solution of mine. When I tried to use Fody (https://www.nuget.org/packages/Fody/) to package my binaries into a single binary, I noticed that this call started returning…
Øystein Kolsrud
  • 359
  • 2
  • 16
0
votes
0 answers

Is it possible to weave into every method of a project using MethodDecorator.Fody?

I understand MethodDecorator.Fody provides a means to define an attribute decorator that can be used on any method throughout the assembly. Is it possible to have it automatically apply to all methods within that assembly? (E.g. as if I decorated…
J.D.
  • 954
  • 6
  • 22
0
votes
0 answers

Application breaks on re-throw Exception Fody

I am trying to handle all the exceptions thrown from a async method, but when i throw the exception after the execution of an async child method,then on re-throw exception from fody(OnException method) application breaks. Like: using…
0
votes
1 answer

How to hide content view from content page view model(Xamarin forms,freshmvvm)

I am adding like this content view which is having its own view model.I want to handle its visibility from view model of content page. Here is…
Dolma
  • 1
  • 1
0
votes
2 answers

Source Not Available on Fody decorated methods

I have the following scenario: Where ProjectA is a simple class library, and ProjectB is a Console Application. ProjectA.Class1.cs contains the following code: using System; namespace ProjectA { public class Class1 { public void…
Nelladel
  • 166
  • 3
  • 12