Monday, September 30, 2013

Stanford Course - Build a Calculator with iOS5

I went thru the Stanford iOS5 code walk thru to build the calculator.  The lecture notes can be found here.

A Few tidbits on the new stuff i learned:

Convert a double to a string - here on the brain object , send title of button pressed to performOperation method which returns a double.  On the NSString method StringWithFormat method, we convert it to a string value
double result = [self.brain performOperation:sender.currentTitle];
NSString *val = [NSString stringWithFormat:@"%g", result];
How to write a getter/setter for a property (in this case an array which get initialized prior to use)
- (NSMutableArray *) operandStack {
     if (_operandStack == nil) {
        _operandStack = [[NSMutableArray alloc] init];
     }
     return _operandStack;
 }
- (void) setOperandStack: (NSMutableArray *) operandStack {
                 _operandStack = operandStack ;
          }

Adding wrapped double in a object to an array:
NSNumber *number = [NSNumber numberWithDouble:operand];
[self.operandStack addObject:number];
 Referencing and then removing object in an array:
NSNumber *number = [self.operandStack lastObject];
if (number)    [self.operandStack removeLastObject]
 Append to current Output String the digit value pressed:
    NSString *newDisplayText = [calculatorOutputText stringByAppendingString:buttonText] ;

Btw, I found this web site cs193p that chronicles the entire course [calculator post]. Another site.  Lastly,  on the apple iOS site  portal or Dev Center, noticed they have section on configuring web applications and things like CSS

One more thing. In the file system on your mac, there is the developer directory. This folder contains about xcode pdf file, a documentation directory, and even a code samples directory.
Related Links:
Objective C Primer
Working with Objective C
NSMutableArray Reference 
NSString Reference

Thursday, September 26, 2013

Don't get iOS 7 yet..

link :
Given all these bugs and issues, combined with some genuine major advances, it’s hard not to interpret this as a beta release that was rushed into production for the release of the iPhone 5S. In a way, it reminds us of the Android 3 release — which was rushed into production for the Motorola Xoom tablet — with severe bugs and performance deficiencies. We’re eagerly awaiting the release of the first update for iOS 7 when we hope Apple delivers on its usual commitment to quality.
I have experienced alot of my applications not working. For example, GMail keeps crashing on iPad and MyFitnessPal on iPhone also crashes when attempting to enter text.

Monday, September 23, 2013

PhoneGap, jQuery Mobile, and Usergrid Learning session from Apigee

Tim Anglade demo on Mobile development from Apigee:

IOS7 Safari

I am not sure how they came up with the share icon with the new release of iOS7 Safari. The stick figures are going to take a long time getting used to. This article goes into extensive detail on the new browser.

http://www.mobilexweb.com/blog/safari-ios7-html5-problems-apis-review

Before the IPhone I never really paid much attention to the Mac culture but the products are great. I guess if you look closely enough you can find faults or stuff you don't like.

This big overhaul in this release of the GUI is pretty dramatic in the amount of changes.  I have found that they stick with their designs and only change when there are flaws.

Sunday, September 22, 2013

Sencha Touch Lab


Sencha Touch with Yelp using architect tool


http://api.yelp.com/business_review_search?ywsid=[Insert Yelp Key here]&term=hotels&location=Raleigh NC
6djP8TRGT_8JrGgJOsdwYQ

Restaurants Store URL:
http://api.yelp.com/business_review_search?ywsid=[Insert Yelp Key here]&term=eat&location=Raleigh NC

Shops Store URL:
http://api.yelp.com/business_review_search?ywsid=[Insert Yelp Key here]&term=shops&location=Raleigh NC

Data distance

Data Distance 

http://www.cfwhisperer.com/
Spedy  http2
Jmeter
Distance between. Hard drive and user
bigmemory-heap-envy
Cache headers
Ehcache couchbase app caching
Web server caching nginx
Database caching external memcached
http://www.terracotta.org/big memory
Trace route tool tracert