Articles Tagged 'OO'

XCode: organize your code with the # pragma mark

XCode is a very powerful and versatile and provides the programmer with many useful features and simple to use. When writing complex code, or at least articulated, it becomes important to organize your code so you do not waste time searching functions spread in long lines of code. After commenting, the first and most important thing to do, the environment XCode provides guidelines (nice) to improve the usability and legginilità within the development. One of these is the directive #pragma mark that becomes very useful in organizing groups of the code and methods.

In the picture below you can see the code part of my project PragmaTest :

pragmamark-1

The top dropdown menu allows you to list all the methods of our class. Now if we insert our method over the directive #pragma mark which has a syntax:

1
# Pragma mark {label}

We get:

pragmamark-2

The first #pragma mark with a hyphen (-) inserts a separator line. The second is a text (label) to taste. You can add the following statement where you want, organizing the code as you see fit. You can enter more pragmatic lines, type:

1
2
3
4
5
6
# Pragma mark -
# Pragma mark / **
# Pragma mark * Using the pragma
# Pragma mark * on several lines of code
# Pragma mark * /
void ) mioMetodo { } - (Void) {} myMethod

Continued ...

Job in saidmade: Programmer Wanted

Saidmade Ltd. , despite the apparent moment of crisis, provides a great opportunity for young computer enthusiasts. The 'real job offer is addressed to all those who wish to work as a developer, a profession that requires passion and desire, often underestimated, especially here in Italy. The company of which I am a member, then, is looking for a Programmer / Junior Programmer with the following requirements:

  • Age between 18 and 27 years and a good dose of creativity
  • Basic knowledge of programming and especially of language ANSI-C

Desire to acquire knowledge of:

  • OO
  • PHP
  • JavaScript
  • Adobe Actionscript
  • C + + / Objective-C

It is also an advantage of knowledge:

  • XHTML / CSS
  • WordPress

If your profile and your interests are reflected in the above, please send your proposal to condidatura: info@saidmade.com

Continued ...

Overloading

Overloading is a very useful feature of some programming languages ​​to objects. However tuti OO languages ​​do not support it, and some of the "implementing" or limited to or different. In general, functions or methods, overloading allows you to create two or more functions / methods that have the same name but accept different parameters, for example:

Continued ...