-
Pattern: Adapter
Description Adapter design pattern allows the interface of an existing class to be used as another interface.It is often used to make existing classes work with others without modifying their source code. Examples in .NET : SQLiteDataAdapter EncodingAdapter Learn More Wikipedia Homework iPhone 7 does not have a headphone jack. Implement an adapter that will…
-
Pattern: Builder
Description The intent of the Builder design pattern is to separate the construction of a complex object from its representation Examples in .NET : UriBuilder SqlConnectionStringBuilder Learn More Wikipedia Homework Imagine that you have a logger that logs to a file and to a console. Implement a builder that will allow you to create a…
-
Pattern: Iterator
Description Iterator design pattern allows to traverse a container and access the container’s elements. Example in .NET : DirectoryEnumerable Learn More Wikipedia Homework With the Yield keyword implement a function that return an IEnumerable of generic int that will return the first 10 numbers of the Fibonacci sequence
-
Pattern: NullObject
Description Instead of returning null,use an object which implements the expected interface,but whose method body is empty. Examples in .NET : EmptyFolder NullLogger Learn More Wikipedia Homework When retrieving data( e.g. a Person with ID =-1 ) from a database,return a NullObject instead of null. How you will verify that the object is a NullObject?
-
Friday Links 455
Heat.js – JavaScript Heat Map twitter.com/cassidoo/status/1723873293625684122 GitHub – andrijac/ruler: Simple on-screen pixel ruler. The Query Options API | TkDodo’s blog console.delight – Frontend Masters Boost Brains Are Not Required When It Comes to Thinking and Solving Problems–Simple Cells Can Do It | Scientific American GitHub – viceroypenguin/SuperLinq: Extensions to LINQ to Objects You are never…
-
Comparing EFCore Database Providers part 3
I did not have the opportunity to migrate from a database from another . But seems to me that,when using EF,the principal problem will be the stored procedures,not the code that EF ( and providers) are generating automatically. Yes,there are some problems ( see part 1 and part 2),but those seems not so important and…
-
Comparing EFCore Database Providers-part-2
I have started with a simple table – Department( id autogenerated,name) and generate EFCore context and classes with scaffolding templates https://learn.microsoft.com/en-us/ef/core/managing-schemas/scaffolding/templates?tabs=dotnet-core-cli . Then I have created a simple text ( XUnit + LightBDD ) in order to test – generateDatabase from classes – CRUD – some simple search . Works perfectly,so to the next –…
-
Introduction in Roslyn Code Generators & Building Your Own Search Assistant
Azi la 19:30 avem o noua intilnire ADCES Presentation 1 : Introduction in Roslyn Code GeneratorsDescription:Presenter : Ignat Andrei,http://msprogrammer.serviciipeweb.ro/Presentation 2: # Building Your Own Search Assistant: A Hands-On Guide to Internet-Connected AI ToolsDescription:Ever marveled at Microsoft’s Copilot knack for discussing up-to-the-minute topics,despite being trained on data up to only September 2021? Curious about the magic…
-
Comparing EFCore Database Providers-part-1
I wanted to see if there are any differences in EFCore database providers listed at https://learn.microsoft.com/en-us/ef/core/providers/?tabs=dotnet-core-cli I want to test the capabilities for each one within a standard choice of tables,in order to know the capabilities I choose only those that have a version for current STS / LTS,whatever it is current. ( I am…
-
Friday Links 454
bitjson/qr-code: A no-framework,no-dependencies,customizable,animate-able,SVG-based HTML element. twitter.com/kevin2kelly/status/1749204538173919676 Optimizing SQL Queries by 23x!!! – DEV Community why lowercase letters save data | endtimes.dev Measuring developer productivity? A response to McKinsey Introducing the MSTest Runner – CLI,Visual Studio,& More – .NET Blog 2023 Year in Review | Blog My Approach to Building Large Technical Projects – Mitchell Hashimoto…
I am ok , you are ok