W skrócie jak ustawić czas systemowy z poziomu .neta, a przy okazji jak wywołać funkcję z pewnej dllki.
[DebuggerTypeProxy] is very useful attribute when you have a class that inherits from another class and that one inherits from another one, and some of the classes contain collections of items and hundreds of properties that in fact are not important to you… Strictly speaking, when displaying class’ members while debugging makes you feel like quitting the job. [b]We decide how to display object while debugging[/b] Exactly! You can set a proxy that will inform debugger how you want a type to be displayed...
Last Tuesday, I had a talk in Wrocław about async/await in C# (thanks once again, you rock!). At some point, I asked the audience seemingly simple question. Why do we need async keyword at all? When I look at the folks, lots of them looked very confused since the answer seemed very obvious. Well, as you probably expect, it’s a little bit more complicated. Async makes my method asynchronous… At the very beginning, I should explain why the answer to my ques...
Sztuka programowania 2011 dni, 20 godzin, 34 minuty temu 290 źrodło rozwiń
Wpis o tym, jakie mamy modyfikatory dostępu i jak je olać ciepłym moczem;)
Sztuka programowania 2016 dni, 19 godzin, 6 minut temu 254 źrodło rozwiń
Chciałbym dziś napisać o jednej z metod poszerzania wiedzy. Od zawsze nazywało się to dla mnie The Morning Brew. Jak sam autor pisze: The Morning Brew is a daily .NET software development link blog published by Chris Alcock a software developer from the north west of England. Chris ma w tym doświadczenie, to już #2468 odcinek, pierwszy był 10 lat temu!
Chcemy rzucić wyjątkiem, gdy mamy przypadek nieobsłużony poprzez case’y. Na przykład gdy pojawiła się nowa wartość enuma Shape. throw EnumGuard.CreateMissingEnumException(nameof(shape), shape);
Sztuka programowania 2017 dni, 20 godzin, 26 minut temu 194 źrodło rozwiń
Czas na nową serię – czego nauczyłem się danym tygodniu. W tej serii będę się starał napisać klika słów oraz zamieści kilka linków z tego czego nowego nauczyłem się danego tygodnia. Gdy nie będę miał materiałów no cóż albo urlop albo wstyd (wstyd nie nauczyć się czegoś codziennie). Ponieważ inne serie się sprawdzają (z newsami) więc ta też powinna się przyjąć. Na każdym „zaangażowanym” blogu programistycznym jest jakaś seria. Prawdziwa fala przeszła z kursami na meila-a. Zapraszam serdecznie. W tym ...
Sztuka programowania 2027 dni, 20 godzin, 8 minut temu 216 źrodło rozwiń
Najbardziej popularnym Value Object jest Money. W tym przykładzie instancje możemy tworzyć tylko poprzez metode Create() (taka fabryka). Konstruktor jest prywatny. Pewnie dla tego przykładu lepiej mieć po prostu publiczny konstruktor z dwoma parametrami, ale mam wiele przykładów innych bardziej skomplikowanych Value Objects, gdzie podejście z prywatnym konstruktorem i kilkoma fabrykami walidującymi różne przypadki ma sens.
Sztuka programowania 2030 dni, 20 godzin, 25 minut temu 136 źrodło rozwiń
Opublikowane w przez szymadmin W poprzednim odcinku (link) , mogliście przeczytać na temat stworzenia projektu w asp.net core, Depedency Injection oraz innych niuansach. Dzisiaj przejdziemy do części praktycznej -> użycie jej. Czym jest, jak się to je – jest to mikro obraz konkretnego środowiska, z daną wersją i w danym projekcie otwartym na konkretnym porcie. Wspierany jest przez wiele platform i firm, które udostępniają swoje obrazy na dockercloud. Dla przykładu, użyty przez nas asp.net core, serwery...
A few days ago I watch a very interesting talk from NDC given by Jon Skeet, Kathleen Dollard and Rob Conery. Around 41:15 minute Kathleen said something very interesting about protected internal...
Sztuka programowania 2043 dni, 21 godzin, 23 minuty temu 232 źrodło rozwiń
Welcome to the first part about DevOps and automating the deployment for the .NET Core apps with the usage of Docker, Travis CI (I’ll also mention how to use BitBucket Pipelines) and Rancher. The purpose of this tutorial is to show you that setting up the CI & CD for the projects that you’re working on is not as complex as it may seem at the first glance. The slides for the presentation can be found here.
When I browse StackOverflow questions tagged with selenium label, a lot of them are related to the problem of clicking on page elements. It seems to be one of the most trivial tasks, but can cause a lot of problems. Very often invoking Click() action on webelement ends with exceptions (there is a wide range of them). The main reason is that element on which we try to click is not in “Interactable” state. There is a lot of different factors that can cause that situation:Element has zero dimension (width ...
Wspólna nauka wzorców projektowych, na pierwszą linię idzie Obserwator. Zachęcam do komentowania i dzielenia się spostrzeżeniami.
Sztuka programowania 2063 dni, 21 godzin, 11 minut temu 291 źrodło rozwiń
C# Attributes are very popular for ‘decorating’ assembly with some additional data, usually influencing on the application’s behavior or the way data are managed. You probably already used at least some of them – Obsolete, Serializable, Required, Display, MaxLength, RegularExpression, WebMethod are only a few of hundreds available in .Net world. What is more, you can write your own custom attribute and use it like a build-in one. I will write more about this in the next post. Right now, let’s focus o...
Sztuka programowania 2067 dni, 21 godzin, 27 minut temu 166 źrodło rozwiń
Written by Dawid Sibińskion As you may know, in my MoneyBack Xamarin.Android application I’ve used SQLite as the local db management system. Recently I’ve added an ASP.NET Core web solution to my GitHub repository in order to create back-end API for my mobile app. I wanted to have database hosted on a remote server and Android application to synchronize its data with it. Then I started wondering… and decided to make a deeper research first. As I wrote in my post summing up DajSiePoznac2017 comp...
Architektura 2072 dni, 21 godzin, 52 minuty temu 36 źrodło rozwiń
Mobile development 2072 dni, 21 godzin, 52 minuty temu 47 źrodło rozwiń
Cześć. Dużo się ostatnio naoglądałem i naczytałem o DDD i architekturze port-adapter i tak zacząłem rozmyślać jak to osiągnąć, choćby w kontekście tooli, które piszę do swojego silnika. Z tego co zauważyłem, to w projektach z którymi przyszło mi pracować, większość klas jest publiczna. Jest to zrozumiałe, chcemy mieć testy lub nie mamy testów, ale wszyscy piszą public, więc co to za problem. No niestety problem jest, wynika on z tego, że udostę...
Sztuka programowania 2077 dni, 22 godziny temu 180 źrodło rozwiń
Stale rosnąca baza pytań rekrutacyjnych dla programistów.
Do You ever wanted to run C# code in a scripty inline way to check if code will execute the way you want? This could be especially useful when you don’t have powerful visual studio with repl(interactive) and You are writing C# in something lightweight like vs code. I decided to write this post because installing scriptcs is cumbersom...
Każdy z programistów, który choć raz miał do czynienia z wielowątkowością, chociaż raz musiał użyć konstrukcjo lock(). Dlaczego nie wolno tego używać razem z async/await? I co użyć zamiast tego? O tym w dzisiejszym wpisie.
Sztuka programowania 2092 dni, 23 godziny, 17 minut temu 311 źrodło rozwiń