-2

Can I make POST or GET requests from an iphone application?

In this article, the second answer mentions 'Assume your class has a responseData instance variable, then.' What does this mean and how would I add one?

Thanks!

Community
  • 1
  • 1
neutrino
  • 341
  • 1
  • 3
  • 19

1 Answers1

1

In your class's header file, there will be a section along these lines:

@interface YourClass : NSObject {
    NSMutableData *responseData;
}

// Soem method declarations here
@end

Inside, the braces, add a declaration for the instance variable you want:

@interface YourClass : NSObject {

}

// Soem method declarations here
@end

I'd recommend reading The Objective-C Programming Language if this is unfamiliar to you, because there are a lot of aspects of the language that are more subtle than this.

Chuck
  • 234,037
  • 30
  • 302
  • 389