Coder Social home page Coder Social logo

linqspecs's People

Contributors

grmagic avatar jfromaniello avatar navozenko avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

linqspecs's Issues

.NET Standard supporting

There is an idea to add .NET Standard support to allow using LinqSpecs on the .NET Core. Unfortunately, the existing LinqSpecs code is not fully compatible with .NET Standard versions 1.0-1.6 because there is no SerializableAttribute in .NET Standard 1.0-1.6. All specifications in LinqSpecs are marked with the [Serializable] attribute and support binary serialization. Is it really necessary? Should we remove the [Serializable] attribute for compatibility with .NET Standard?

Stack overflow with Custom Spec

I've created a custom spec class similar to the "CustomerFromCountrySpec" in the README.md. When I create my custom class, within a second or two I get a stack overflow.

Here's my class:

public class CustomSpec: Specification<string>
{
        public string Name { get; set; }

        public CustomSpec(string name)
        {
            Name = name;
        }

        public override Expression<Func<string, bool>> ToExpression()
        {
           return  s => s == Name;
        }
}

Here's my test method

[Test]
public void CustomClassShouldntStackOverflow()
{
            var s = new CustomSpec("Jose");
            Assert.True(true); //Put a break point here and let it set for 5 seconds, you'll stack overflow.
}

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.