Use Reflection.Emit to precompile expressions in MSIL

Hello, Habr! I present to your attention the translation of the article " " Using Reflection.Emit to Precompile Expressions to MSIL "By Steve Marsh.


The classes in this project allow you to analyze the textual expressions entered by the user, and compile them into the .NET assembly. This assembly can be run "on the fly" or stored in the DLL. Pre-compilation of expressions allows to provide a high level of portability and allows very effectively evaluate the user input logic. In addition, we can use the ildasm.exe tool from Microsoft to open and verify the generated base ...[/h]
.NET / C#
+ 0 -

Release of Apache Ignite 2.4 - Distributed Database and Caching Platform

On March 1? 201? 4 months after the last version, Apache Ignite 2.4 was released. This release is notable for a number of innovations: support for Java ? multiple optimization and SQL improvements, support for a neural network platform, a new approach to building a topology when working with a disk, and much more.
Apache Ignite Database and Caching Platform Is a platform for distributed data storage (optimized for active use of RAM), as well as for distributed computing in near real time.
Ignite is used where it is necessary to process very quickly large data streams that are too tough ...
+ 0 -

Upload messages using the Telegram API. Where to start

On the Internet, you can find many descriptions and examples of creating telegram bot. But Telegram Bot Api has limited functionality. To solve the task of unloading messages from Telegram by keyword, you must use the Telegram API. The library was used as a basis. TLSharp . It should immediately be clarified that further work is possible only for registered users in Telegram.
The start of working with the API is registering the application:
We go to the site Telegram and enter your phone number. Enter the verification code.
Upload messages using the Telegram API. Where to start
We f...
GitHub / C# / .NET
+ 0 -

About life, freedom and the pursuit of happiness of the user API

About life, freedom and the pursuit of happiness of the user APIWe are constantly confronted with systems created by other people. Whether it's UI applications in a smartphone or the cloud infrastructure of the modern Internet - it is the interaction process that determines our feelings, impressions, and ultimately - the attitude to technology. We can be in the role of engineers, developers or ordinary users - user experience is important everywhere. Around the systems with good UX, a society of happy, contented and productive people is formed; a bad UX only leads to pain and suffering.
Even if you do not pay attention to yourself, creating a new software...
+ 0 -

Fantastic-Elasticsearch. How did we "tame" the clever search for documents

Full-text search makes it possible to search documents by text content. Such a need may arise when the system contains many text entities, and users need to consider this data during the search. We encountered a similar situation when developing a solution for workflow *. These systems are stored in MS SQL Server or PostgreSQL, and flexible attribute search allows you to find documents for various meta-information. However, over time this became insufficient. Before us the task arose: to learn to search documents on text properties and attached files.
Fantastic-Elasticsearch. How did we "tame" the clever search for documents ...
+ 0 -

Let's explore the minor features of C # 7

C # 7 adds a number of new features and focuses on data consumption, code simplification and performance. The biggest features have already been considered - tuples , local functions , comparison with sample and throw expression . But there are other new opportunities, both large and small. They all combine to make the code more efficient and understandable, so that everyone is happy and productive.
Let's look at the rest of the features of the new version of C #. So! Let's start!

Out variables are

Currently in C # use out parameters ...[/h]
.NET / C#
+ 0 -

Creating a network with Internet access in the GNS3 environment on Windows 10

Creating a network with Internet access in the GNS3 environment on Windows 10 GNS3 (Graphical Network Simulator) Is a graphical network simulator that allows you to simulate a virtual network from routers and virtual machines. An indispensable tool for learning and testing. Works on almost all platforms. Great for creating stands on desktop machines.
Depending on the hardware platform on which GNS3 will be used, it is possible to build complex projects consisting of Cisco routers, Cisco ASA, Juniper, and servers running network operating systems.
GNS3 has two serious drawbacks:
Strongly demanding of CPU and memory. 10 routers are already heavily loaded ...
+ 0 -

Database and DBMS research using T-SQL


Greetings again, dear reader Habra!
When your realized ideas, experience, as well as all the information that does not give rest, you make out in the publication, sooner or later a logical point comes to the entire previously written information flow. This article will be different from all previously published by me my looseness and freer style of text presentation, and also she will finish the presentation of all my accumulated experience on MS SQL Server.
This article is in addition to article Let's explore the databases using T-SQL , and also briefly tells ...[/h]
+ 0 -

And you know where you can apply expression's in your project or optimize the creation of tests

0. The lyrics are

Let's talk about unit testing. For large and age-related projects, the problem of "thick" services is very actual. I am now talking about a large number of dependencies passed to the constructor. If we add to this a few dozen methods that need to be tested, it becomes obvious that a lot of time is spent on wetting unnecessary parts. The problem will be solved by automation. those. Creation of an instance of the required type and wetting of unused dependencies during execution.
It turns out we need
var myService = new MyService (A.Fake
(), new Sevice2 (),
+ 0 -

You can not just take and edit the subtitles

You can not just take and edit the subtitles
How many people use subtitles around the world? Probably very much. For educational purposes or simply because of the love for the original voice acting, on the Internet you can find subtitles almost to any film and in many languages. All this is created in special programs. As in most programs, Subtitle Edit did not do without surprises in the form of bugs.
Subtitle Edit - Free editor with a huge list of features. This is a large open source C # project. The program is very popular and is issued in the first lines of search engine results, many awards are listed on the project website. In the ...
+ 0 -