The window.requestIdleCallback Function in JavaScript

Calling this function we should pass over the function we want to be invoked in the background in those moments when the one and only thread is free (not busy with other tasks). <!DOCTYPE html> <html lang=”en”> <head> <meta charset=”UTF-8″> <title>Title</title> </head> <body> <script> function doInBackground() { console.log(“doing work in background”); } if (window.requestIdleCallback) { […]

Private Attributes in Python

Python allows us to define private attributes in our class (private instance variables). Outside the scope of the class it won’t be possible to access them. In order to create private attributes we should prefix their names with two underscores (‘__’). class Rectangle: def __init__(self,w=10,h=10): self.__width = w self.__height = h def area(self): return self.__width*self.__height […]

The use warnings; Statement in Perl

Adding this statement to the begining of our code will trigger warnings for our code wherever relevant. Adding ‘use warnings Fatal => ‘all’; to our code will promote all warnings to errors and die immediately on the first warning. #!/usr/bin/perl use strict; use warnings; my %currencies = ( USD => 4.1, EURO => 4.4, GBP […]

The use strict; Statement in Perl

The Perl programming language started as a hack, as a tool that its sole purpose was to fulfill specific needs. When Perl’s popularity grew and more and more people started to use it was already too late to enforce rigid grammar rules. Adding the ‘use strict;’ statement in the beginning of the file will enforce […]

The Scala Programming Language Colloquium

On Sunday Novemebr 22th I will deliver a short seminar about the Scala programming language. The seminar will take place in HIT (www.hit.ac.il) room 424 building 8 (computer science department) at 1500. During this seminar I will overview my thoughts about using this programming language in academic courses and focus on its strengths as a […]

Binding Objects with Functions in ECMAScript 2016

The development ECMAScript 2016 has already started. One of the coming new capabilities will allow us to bind a function to specific object in order to be notified of changes that take place in that object. This capability is already supported in Google Chrome! This following code sample shows this capability in action. You can […]

Java EE Platform Shenkar October 2015

During the winter semester in years 2015-2016 I am going to deliver in Shenkar a course that focuses on server side software development. The course focuses on Java EE. You can find the syllabus at http://www.lifemichael.com/shenkar/javaee201510.pdf. You can find the detailed plan at https://docs.google.com/spreadsheets/d/1KALld-WOPv9eveR8kQkkEhwzDtQuHBWQduaLbsuFCsA/pubhtml. You can find the Google Community I created in order to […]

Scala Programming HIT October 2015

During the winter semester of 2015-2016 I am going to deliver in HIT a course that covers both Java and Scala. The course will take place every monday 1200-1600. You can find the syllabus at internet_programming_2015_10_he.pdf. You can find the detailed plan at https://docs.google.com/spreadsheets/d/1N72s7PXOigx0Q3evNyjWpsA8dYuPEaK-aPZLW8baKb8/pubhtml You can find the Google Community I created for this course […]

Java EE Platform HIT October 2015

During the winter semester in years 2015-2016 I am going to deliver in HIT a course that focuses on server side software development. The course focuses on Java EE. You can find the syllabus at http://www.lifemichael.com/hit/java_ee_fixed_2015_10_he.pdf. You can find the detailed plan at https://docs.google.com/spreadsheets/d/1zp39DjDCOU39cqPN-fRMDoUOu3F2wILgIeO8A3xKebU/pubhtml. You can find the Google Community I created in order to […]

XAMPP, MAMP & MongoDB

In order to execute code in PHP that interacts with the MongoDB server you should install the MongoDB driver in your PHP execution environment. Using MAMP, I spent lots of hours finding out that MAMP doesn’t come will all source code files of PHP in order to allow you building the mongo.so file. The mongo.so […]

Update cookies preferences