last edited May 13, 2008 12:03:17 (87.194.80.139) CocoaDev is sponsored by: Panic: Shockingly good Mac software! HowToConvert I wrote up a function to decode some Base64 text and return it. Here is the (somewhat messy) code I made: - (NSStrin... 続きを読む
Google Toolbox for MacA collection of source from different Google projects that may be of use to developers working other Mac projects. To browse the Google Toolbox for Mac source code, visit the Source tab. Library changes are documented in... 続きを読む
Overview A strict JSON parser and generator for Objective-C. It adds categories to existing Objective-C objects for a super-simple interface. More flexible APIs are also provided for added control. Documentation API documentation generated fr... 続きを読む
This framework implements a strict JSON parser and generator in Objective-C. Download the framework, embed it in your application, and import the JSON/JSON.h header. You're now ready to make your application speak JSON. The framework adds cat... 続きを読む
So here is something a lot of people have been wondering to do in the forums. How do I take a UIImage or any image and post it to a website. So this will go over how to do that. There are two ways to tackle this issue. One we can base64 encod... 続きを読む
Hi I'm trying to send a multipart/form-data 'POST' request using NSURLRequest, including several keys, but also an image. I'm not particularly knowledgeable on HTTP request (and pretty new to Cocoa, to be honest...) If you want to know what i... 続きを読む
iOS 4 introduces one new feature that will fundamentally change the way you program in general: blocks. Blocks are an extension to the C language and thus fully supported in Objective-C. If you’re coming from a programming language such as R... 続きを読む
0.4.26 GHUnit is a test framework for Objective-C (Mac OS X 10.5 and above and iPhone 3.x and above). It can be used with SenTestingKit, GTM or all by itself. For example, your test cases will be run if they subclass any of the following: GHT... 続きを読む
I need to invoke an initial GET HTTP request with Basic Authentication. This would be the first time the request is sent to the server and I already have the username & password so there's no need for a challenge from the server for authoriza... 続きを読む
There is a supported API for accomplishing this! Add something like this to your NSURLConnection delegate: - (BOOL)connection:(NSURLConnection *)connection canAuthenticateAgainstProtectionSpace:(NSURLProtectionSpace *)protectionSpace { return... 続きを読む
There are tons of goodies in Snow Leopard for developers, but one of my favorites is associated objects, which allow you to tack arbitrary key/value pairs onto any NSObject. Since there’s no documentation whatsoever, I thought I’d introduce... 続きを読む
September 13, 2009 Among the many numerous developer improvements in Snow Leopard is the addition of blocks to the Objective-C language (now at version 2.1). While working on some networking code using NSURLConnection I discovered that blocks... 続きを読む
iPhone の流行により、 Objective-C に興味のあるプログラマが増えてきたので、ここに Objective-C のクイックリファレンスを書くことにします。対象は、すでに他のオブジェクト指向言語習得者です。たとえば、Java や C++ といったプログラマを対象としていま... 続きを読む
まだあまり相手にされていない感じの Blocks ですが、使うことができるシーンは結構あります。 NSURLConnection を使用すると、簡単にWEBからリソースを取得できますが、多少記述が多くなってしまうのと、デリゲートによって処理が散らばってしまうのが問題です... 続きを読む
I've had significant success with NSURL, NSURL[Mutable]Request, NSURLConnection with my iPhone applications. When trying to compile a stand alone Cocoa application, 10 line program to make a simple HTTP request, there are zero compiler errors... 続きを読む
Here's a common development scenario: You've just finished building your application. You're confident that it works. You've put it through the paces, exercising every feature and checking every output. You're proud to say that it's stable, a... 続きを読む
関数呼び出しという形ではなく、メッセージという形でオブジェクト同士のやり取りを行う。 [targetName messageName] でターゲットにメッセージを送る。 ターゲットにmessageNameメソッドが実装されていればそのメソッドが呼び出される。 NSString * string; //... 続きを読む
Java基礎文法最速マスター - 何かしらの言語による記述を解析する日記を参考に、Objective-Cのものを書いてみた。まだまだ歴が浅いので間違っている所があるかもしれません。 基礎デバッガコンソール出力Xcodeのデバッガ出力を行うにはNSLog関数を使います。pri... 続きを読む
Xcode includes OCUnit, an Objective-C unit testing framework, and support for running unit tests (OCUnit or otherwise) as part of your project's build process. Xcode's unit testing support is described in the Xcode Unit Testing Guide. I've wr... 続きを読む
June 6, 2005: Apple is now distributing OCUnit as an integral part of XCode 2.1 Test first, develop later! OCUnit is a testing framework for Objective C in the Mac OS X, Mac OS X Server, GNUSTEP, YellowBox/Cocoa and WebObjects/Objective C env... 続きを読む
mac, c, objc | 22:35 | Blocks というのは Apple が C/C++/Objective-C 向けに独自実装したクロージャ的な機能.Snow Leopard リリース時に GCD すげぇ!という記事で見かけて『Apple やりやがった,あの変態やりやがった』くらいにしか思っていなかったのだけ... 続きを読む
もりやまです。先日初めて仕事として iPhone アプリの開発に携わりました。 iPhone アプリの開発が解禁された直後に少し齧って、今回ほぼ 2 年ぶりに触ってみたんですが、相変わらず ObjC には慣れないですね・・・ さて今回は、そんな ObjC での開発で、iPhone... 続きを読む