Protocol-Oriented Programming is a new programming paradigm which is used by Swift. In the Protocol-Oriented approach, we start designing our system by defining protocols then the protocol extensions, protocol inheritance, and protocol compositions which allow us to add a new functionality not only to one type, but to a whole collection of types that all conform to the same protocol.
The value types in Swift like struct or enum cannot inherit from other structs or enums which means we cannot use inheritance with value types, but the value types can inherit from protocols, even multiple protocols which is the most…
AVFoundation is a multimedia framework with APIs in Objective-C and Swift which provides high-level services for working with time-based audiovisual media and combines six major technology areas which will go through each one in more details up and running, so let’s start with the first area in this article:
songURLfor the audio which wanna play.
playerand hold the reference of…
Before starting playing, streaming, recording sounds or configure how your application and the operating system should respond to the interruptions, we need to take a small journey to the Core Audio and some definitions about the audio just to get the full picture. In the next parts will talk in more details up and running.
Core Audio is the digital audio infrastructure of iOS and OS X. It includes a set of software frameworks designed to handle the audio needs in your applications which is optimized for the computing resources available in a battery powered mobile platform.
Will talk about how we can use Apple Combine with Core Data but if you like to read more about Core Data itself and how can we use it to save, fetch and delete the entities you can read the previous article about Core Data with Sugar Syntax.
First we will need to create a custom Combine Publisher and fortunately it’s super easy to do that we will need just 3 steps to do it but before doing that we need to understand how the publisher actually work, so let’s talk about that for a bit before applying our customer…
When I started iOS programming since years ago I was mixing up between the Core Data and the Database, but in fact the Core Data is not a database even Core Data is actually backed by an SQLite database but both of them are ways of providing searchable and persistent storage. In short description we can say that SQLite is a database itself and Core Data is an ORM (Object Relational Model) which creates a layer between the database and the UI.
Core Data is a framework that you use to manage the model layer objects in your application. It…
Now let’s leverage what we have learned and apply into real examples.
NSObjectand the property should be
In Part 1 talked about what’s Combine and how we can understand and use it and in this part will go continuing the examples of the usage.
a is: 1 b is: 4
a is: 2 b is: 4
a is: 0 b is: 4
a is: 3 b is: 4Value is: 4
Value is: A1 Value is: A2 Value…
The Combine framework provides a declarative Swift API for processing values over time. These values can represent many kinds of asynchronous events. so in an imperative programming setting
a = b+c would mean that
a is being assigned the result of
b+c, and later, the values of
c can be changed with no effect on the value of
a, but in reactive programming, the value of
a is automatically updated whenever the values of
c change, without the program having to re-execute the statement
a:=b+c to determine the presently assigned value of
a . Wikipedia
Have you ever pushed a commit on your branch and your commit did fail and then you fixed your commit and pushed again?
The solution to get rid of that is so easy and thanks for Git Hooks which offers
pre-commit for us which’s used to inspect the snapshot that’s about to be committed to see if you’ve forgotten something, to make sure tests run or to examine whatever you need to inspect in the code.
If you went deep in
.git folder you will find a lot of samples for the hooks. …
In this part will talk about how to integrate your project with fastlane to save time for sending TestFlights and releasing via Bitrise.
In these steps we will walk through integrating fastlane with Xcode project on your machine:
1- Installing fastlane.
Install the latest Xcode command line tools:
Then install fastlane using:
# Using RubyGems
sudo gem install fastlane -NV# Alternatively using Homebrew
brew install fastlane
2- Setting up fastlane. Navigate your terminal to your project’s…
Senior iOS Developer, Berlin, Germany