Skip to content

Support inheritance, abstract classes, and virtual members #52

@RKukharchuk

Description

@RKukharchuk

Hi, thanks for this library.

I'm having an issue with using projectable in the base class that needs to get a projectable expression from its derived classes.
The base class is an abstract class.
Derived classes are EF entities.
The base class has projectable property Status, which needs data from derived classes. Adding an abstract member right now fails with a LINQ translation error.
Base class member:

[Projectable] public Status Status => IsActive ? Status.Active : Status.Pending
public abstract bool IsActive { get; }

Derived class:

[Projectable] public override bool IsActive => EndDate > DateTimeOffset.Now; 

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions