Yawnder
Yawnder
CC#
Created by Fat Lenny on 9/21/2024 in #help
difference between a normal variable and one declared with that property shorthand garbage
Let me get this straight: You don't understand something, and you go about calling it garbage, and you expect a positive response?
40 replies
CC#
Created by Denge on 9/4/2024 in #help
Testing multi layered .NET application
I don't see what isn't done properly based on your code, but if it returns null, then there must be something wrong.
4 replies
CC#
Created by Denge on 9/4/2024 in #help
Testing multi layered .NET application
Which probably leads to the actual issue: You probably didn't do the setup of your mocks.
4 replies
CC#
Created by Denge on 9/4/2024 in #help
Testing multi layered .NET application
@Denge First, I would suggest you create your generally Mocks with MockBehavior.Strict, this way they fail if the mocked behavior isn't setup.
4 replies
CC#
Created by Core on 8/22/2024 in #help
✅ EF Best way to do UPDATE on entity
Great! Good luck! Gotta go to bed now 😛
24 replies
CC#
Created by Core on 8/22/2024 in #help
✅ EF Best way to do UPDATE on entity
I'm not certain of what specifically you're talking about, so it's hard to give an advice on that.
24 replies
CC#
Created by Core on 8/22/2024 in #help
✅ EF Best way to do UPDATE on entity
This logic should generally be implemented at the service/logic level, since it's at that point that you know how to handle what. If you want, you can let some exceptions through, like the DbUpdateConcurrency exception, and have these handled by a middleware.
24 replies
CC#
Created by Core on 8/22/2024 in #help
✅ EF Best way to do UPDATE on entity
Where I'm working at now, there is a senior dev that has been using .Net for almost 20 years now, and they still want to use repositories to wrap EF 😛
24 replies
CC#
Created by Core on 8/22/2024 in #help
✅ EF Best way to do UPDATE on entity
Just so you know, a LOT of people make this mistake. I've done it too.
24 replies
CC#
Created by Core on 8/22/2024 in #help
✅ EF Best way to do UPDATE on entity
With repositories on top of EFC's repository (yes, EF/EFC already implement the Unit of Work and the Repositories), you lose key abilities like projection and dynamic filtering, unless you add in tons and tons of pass-through that you have to add in, with all the boilerplate that goes with it.
24 replies
CC#
Created by Core on 8/22/2024 in #help
✅ EF Best way to do UPDATE on entity
What does that have to do with anything?
24 replies
CC#
Created by Core on 8/22/2024 in #help
✅ EF Best way to do UPDATE on entity
Just don't add any kind of repositories on top of your DbContext. Just let your service deal with the DbContext directly.
24 replies
CC#
Created by MechWarrior99 on 8/14/2024 in #help
Arrange points in circle with a Sweep parameter
You're right. I stand (sit) corrected. gj
8 replies
CC#
Created by MechWarrior99 on 8/14/2024 in #help
Arrange points in circle with a Sweep parameter
I think that you were just confused when you plotted it and you ploted your "count-1" try for both.
8 replies
CC#
Created by MechWarrior99 on 8/14/2024 in #help
Arrange points in circle with a Sweep parameter
You have 8 points. It's 360 degrees. It means "increase by 45 degrees per point" if you divide properly. You'll have the image of "desired". It holds for sweep 0.5 too.
8 replies
CC#
Created by MechWarrior99 on 8/14/2024 in #help
Arrange points in circle with a Sweep parameter
@MechWarrior99 I think you should just divide by the count. In your "current, sweep = 1.0", to get that graph you divided by "count -1", not by "count" like you state.
8 replies
CC#
Created by Alice on 8/5/2024 in #help
how to use OID parameter in Dapper
Great
11 replies
CC#
Created by Alice on 8/5/2024 in #help
how to use OID parameter in Dapper
Generally, you want to be using more primitive stuff like int, float, decimal, string, date or even Guids, but not full fledged objects.
11 replies
CC#
Created by Alice on 8/5/2024 in #help
how to use OID parameter in Dapper
Dapper isn't a SQL engine, it's an ORM; a tool to access a database.
11 replies
CC#
Created by Alice on 8/5/2024 in #help
how to use OID parameter in Dapper
Well, convert it to a type supported by your chosen SQL engine flavor.
11 replies