Category Archives: Mac OS

Windows Phone Potential?

I normally hear from Windows developer to say that their Windows market share is much bigger than the total of iOS and Android together. And the sales of Windows 8 has bypassed all the sales of iOS and Android from the beginning to now.

Windows Phone 8

Windows Phone 8

It is quite unfair to compare the whole Windows 8 with iOS or Android. And if we do take that demand into PCs and laptops, then why the hell we do not compare the supply side? It is very clear that if Windows 8 could be a shared platform between PCs, tablets and phones, then all the old software, all the old games would have beome compatible to the Windows 8 system in the short amount of time. And many apps for tablets and phones would be quite different than the ones in PC. No, I don’t mean technology, I am talking about the business model, the purpose of the software.

I don’t mean that iOS and Android is a better market than Windows Phone for indie business. These markets have become very competitive and continue being so. You either have to figure out a market niche or be very lucky.

My New Book – 21 years old achievement

21 years old, I got my first book released, I was so excited. Buy it here

Pro iOS Apps Performance Optimization

Pro iOS Apps Performance Optimization

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Today’s iPhone and iPad apps developers are often running into the need to refine, improve and optimize their apps performances. As more complex apps can be created, it is even more important for developers to deal with this critical issue.

Pro iOS Apps Performance Tuning and Optimization covers many common but difficult problems when tuning and optimizing performance for iPhone and iPad apps and how to resolve these problems efficiently. This book gives you the following:

  • Basic knowledge on common problems in iPhone apps
  • Advanced knowledge over data structure, algorithms, multithreading, and network data in iPhone apps
  • Comparison with problems and solutions for Android and Windows Phone apps

After reading this must-have book, you’ll be ready to make the most of the processing power of the iPhone with your apps performance optimization know-how.

 

What you’ll learn

  • Benchmark your apps using emulators and real device tests
  • Increase and optimize UITableView performance in your iOS apps
  • Increase your app performance using image and data caching techniques
  • Tune your apps using algorithms and data structures
  • Improve your parallel data access using multithreading techniques
  • Optimize memory usage for increased battery life and better apps performance
  • Use native C code to address memory leaks or EXEC_BAD_ACCESS

My book: Community and Opportunities


My iPhone Book

My iPhone Book

I am happy to announce that I encountered a book contract with Apress to write about iphone development. This will be a great opportunity and new experience for me when I have never written a real book before.

That is just part of the main content of this blog, I want to share my own thought over community support (as I already said at this blog post about Community Support) and how it would help me to reach this kind of opportunities. An Apress staff contacted me after he read my blog series about iphone development. This helps me to restate again that if you do good thing for other people, chance will come back. Real chance, real value, not an artificial reputation.

Supporting community and make lives better is my personal long-term goal as well as my company’s long-term goal.

 

Advertising:

Visit vworker to hire best employees

iPhone development tools

Working with Iphone development is working with OSX, and we always need good tools and software for both IPhone and OSX environment to boost our productivity and reducing the repetitive, boring jobs

1/ Multitouch, Accelerometer and more : ISimulate

An application allows you to use your real iphone to control the IPhone Simulator. There is nothing better than the real IPhone device to get the real user feeling. The reason is that it will save a lot of time for you when you only build on simulator, debugging on simulator and you have a wide screen to see.

2/ Memory static analyzer : Clang

Help you a lot in the managed memory environment of iphone development. Good news is that the new XCode (3.2) will integrate directly with Clang help you to analyze and find memory leak much faster.

3/ Google tool box for Mac

You cannot write a good iphone app development without writing good unit testing. And I suggest you to use Google toolbox for Mac with a lot of supports, easy to integrate into your project. It is better than the default OCUnit in XCode. It also really runs your code, which takes more time, but gives you a real, better result and can help you to deal with some File IO or real code you need to run when running unit test.

4/ UI Automation Test: XCode Instrument

Stop running the UI everytime you fix a bug or adding new feature. UI Automation Instrument is a best tool for you like robot proxy in web testing.

5/ Screen capture software: Jing

Good, free software with high quality captured video. Good use for demo.

Catupre Screen Software

6/ Chat client: Adium or Imo

Why do I put a chat client here? Everybody need some way of communication, especially if some of your co-workers or clients are not there. In Mac, you can use Adium to integrate a lot of chatting services like Gmail, yahoo…

Logging class/method/variable name in Objective-C

Just a small post for an effective tip in Objective-C.

Usually if you use the

NSString *name = @"Hello World";
NSLog(@"%@", name);.
Output: Hell world

And usually, when we debug the program and viewing the log, we really want to know the class/method/variable name and line number as well. You can manually hard code it like

NSLog(@"ApplicationDelegate - applicationDidFinishLaunching - name - Helloworld");

But, it is really time consuming and repetitive task. For our company, we use

#define NCLog(s, ...) NSLog(@"<%@:%s:{%d}> %s = %@",
[[NSString stringWithUTF8String:__FILE__] lastPathComponent],
 NSStringFromSelector(_cmd), __LINE__, #__VA_ARGS__ , [NSString stringWithFormat:(s), ##__VA_ARGS__])

Another variant of this is (it combines both class name and method name into __FUNCTION__):

#define NCLog(s, ...) NSLog(@"<%s:{%d}> %s = %@", __FUNCTION__, __LINE__, 
 #__VA_ARGS__, [NSString stringWithFormat:(s), ##__VA_ARGS__])

Then you can just use it like NSLog. For example:

NCLog(@"Hello world");

Output: <ApplicationDelegate:applicationDidFinishLaunching:100> name: Hello World

Good luck to your new productivity:). For your programming language, stop using the System.out.println() and Console.WriteLine, find a version of yourself

References:
Log the method name in objective-C posted in stackoverflow

Print out the variable name in Objective-C posted in stackoverflow