C Sharp
DotNet SDK The even version-numbers are the LTS(long term support) versions. For big projects its good to stick to the latest even .Net version. Only opt fo...
DotNet SDK The even version-numbers are the LTS(long term support) versions. For big projects its good to stick to the latest even .Net version. Only opt fo...
Setup After you defined your DB context you can run these commands:
Get first match List<int> numbers = new List<int> { 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 }; int result = numbers.FirstOrDefault(n => n > 5);
Nuget Config file
Get random strings of length between min and max ```` public static string GenerateRandomString(int minLength, int maxLength) { var random = ...
ACID
Fresh installation To work with MS SQL database locally, the easiest way is to run SQL Server 2019 Express or SQL Server 2019 Developer edition locally. The ...
SELECT COUNT SELECT COUNT(*) FROM WITH (NOLOCK)
Pipeline runs: pull requests can require (via branch policy: Build Validation) builds to happen before they can be merged.
Azure DevOps
Compilation Java gets translated into
Check if your variable is part of enum values Stream.of(MyEnum.values()).anyMatch(v -> v.name().equals(strValue))
List Create and init List List<String> ids = List.of("Id1","Id2");
VisualVM Download VisualVM (doesn’t need to be installed) and run it. Run the java application In VisualVM, you should see started application under “...
Create Test via IntelliJ First you need declare the test-folder as Test Sources Root
Java String interns
Spring basic 3 tier pattern You can split your application into 3 layers:
String dataScopes = stream(InstructionType.values()) .filter(party::getInstruction) .map(Enum::name) .collect...
Create Subset of object Source
https://www.joelonsoftware.com/2003/10/08/the-absolute-minimum-every-software-developer-absolutely-positively-must-know-about-unicode-and-character-sets-no-e...
SAML 2.0 Open standard for passing authentication and authorization information between three actors: the principal the service provider the identity ...
Check content of .pfx cert file
CNAME and A DNS entries An A (Address) record maps a domain name to an IP address. A CNAME (Canonical Name) record maps a domain name to another domain name....
TLS facts Even if you don’t understand how it really works, you can assume following points are true:
General
Who the internet see me Useful website to test local area network from outside (does port forwarding works?): https://canyouseeme.org/
This creates an immutable object which can only be created via a builder object. This is nicer than put everything into a constructor.
https://learn.microsoft.com/en-us/dotnet/standard/events/how-to-raise-and-consume-events#example-2
Source
Source
Clean architecture
Builder If you want to instantiate a specific class with a lot of constructor parameters, or the class should be immutable, the builder pattern encapsulates...
SOLID Single Responsibility principle Open closed principle Liksov substitution principle Interface segregation Dependency inversion principle
Using this nuget package
Test comments Include these comments to structure the testcase. //given //when //then
React-scripts If you have a username with spaces on windows, you will have a hardtime to setup a react-script project.
To prevent Cross-Site Scripting attacks on outbound: https://docs.veracode.com/r/Supported_Java_Cleansing_Functions