1 year ago
What the developer on the middle/senior level has to know objc? Unfortunately, there is no accurate line on vertical development. Paradox, but that know what to study, it is necessary to know what you do not know. I tried to remember the most interesting questions which to me were asked most on different interviews, and also expanded them with a set of questions (the same level) from myself. There are no general questions it seems: IoC, design patterns, S.O.L.I.D., etc.
ATTENTION!!! In addition to vertical development it is important also horizontal
ATTENTION!!! (2) Do not write answers to questions to comments, it gives the chance to people independently to understand. However, if you have interesting questions on a subject, I with pleasure will add them to the list.
Of course, it will not replace real-life communication, however will allow to be prepared for interviews not bad.
1 year ago
In last articles I considered unit-tests, this time it will be a question of integration tests. That the example did not leave too big, but also contained material, I decided to write on the example of part of RSS Reader'a. Counterfeit of the answer from the server for check of options of work will be considered. Testing with CoreData will be considered.
On Tuesday Rambler.iOS V which we announced on Habré earlier took place. Experiment with breaking one very large subject on eight reports connected among themselves perfectly took place — thanks to such granulirovannost speakers could concentrate on the aspect of VIPER and prepare really powerful performances.
1 year, 1 month ago
In this article I will tell about an arrangement of blocks (__NSStackBlock__/__NSGlobalBlock__/__NSMallocBlock__), about how there is a capture of variables and as it is connected with in what the block is compiled.
At present, use of blocks in Objective-C begins practically from the first days of studying of this language. But in most cases developers do not reflect as blocks work inside. There will be no magic, I will just tell about it in more detail.
Let's begin from the very beginning as the block in Objective-C looks
What blocks are used to, I will not paint, it is not about it therefore let's consider the interesting moments in practice at once.
Long thought whether it is worth writing this article here as the community will treat it and if to write, then in what hub it has to be addressed. Eventually decided that it will be interesting to some developers to review an example of perhaps failure project which initially was set perspective.
1 year, 1 month ago
And at the same time once and for all we solve a problem of automatic calculation of height of cells.
Disclaimer: Possibly, this method does not provide the best performance, can have a quantity of reefs, make dizziness, sick and a devil, a request not to read to old men and pregnant children.
Creation Overcoming of difficulties — probably the best motivation of the programmer. Not the secret, Xcode contains a great lot of defects, opaque solutions and bugs. Today I will try to find a solution of one of them
1 year, 1 month ago
There was a task that the program sent through web socket the current coordinates on the interval set by the user. Besides, the program has to work in a background and if the user or iOS for any reason unloads it from memory, then it it is desirable that it was restarted and continued work in a background. The objective should be solved only means of iOS without change of server part (any Push Notifications).
To send coordinates on the timer when the program is closed up in a background does not make a problem, for this purpose it is possible to use background location mode for receipt of coordinates and long-running tasks for timers.
But as in iOS there is no such charm as Android Background Services, if manually to complete the program, the code ceases to be executed. Therefore the main complexity is in how as fast as possible to start the program in a background that it continued to carry out the task further if for some reason unloaded it from memory of iOS or if the user rebooted the device or if it manually "killed" the program.
Now about what helped to solve this problem in acceptable option:
1 year, 2 months ago
With an output of iPhone 6s and iPhone 6s Plus, the Apple company provided us absolutely new method of interaction with our phones: gesture of strong clicking. As you know, this function is already available on Apple Watch and MacBook and in MacBook Pro under the name Force Touch. It — literally — added new concept to the user interface.
If you ask a question why Force Touch was renamed on 3D Touch for iPhone, then you not one such. Shortly after Craig Federigi (Craig Federighi) who was also obviously puzzled with the name provided this new opportunity, there were many guesses. What did not arrange the name Force Touch with? It is too much jokes from Star wars?
But there is a difference! It is obvious that Force Touch can recognize only strong clicking whereas the 3D Touch function более sensitive and can select several levels of clicking how strongly you click.