{"id":16203325,"url":"https://github.com/sschmid/gummi-reflection","last_synced_at":"2025-04-07T19:18:31.871Z","repository":{"id":6309812,"uuid":"7544649","full_name":"sschmid/Gummi-Reflection","owner":"sschmid","description":"Reflection for Objective-C","archived":false,"fork":false,"pushed_at":"2013-04-04T15:57:46.000Z","size":342,"stargazers_count":3,"open_issues_count":2,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-02-13T20:44:14.166Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://sschmid.github.com/Gummi-Reflection/","language":"Objective-C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sschmid.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-01-10T16:44:05.000Z","updated_at":"2023-07-03T16:50:17.000Z","dependencies_parsed_at":"2022-09-13T00:12:05.406Z","dependency_job_id":null,"html_url":"https://github.com/sschmid/Gummi-Reflection","commit_stats":null,"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sschmid%2FGummi-Reflection","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sschmid%2FGummi-Reflection/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sschmid%2FGummi-Reflection/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sschmid%2FGummi-Reflection/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sschmid","download_url":"https://codeload.github.com/sschmid/Gummi-Reflection/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247713259,"owners_count":20983683,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-10T09:53:47.593Z","updated_at":"2025-04-07T19:18:31.844Z","avatar_url":"https://github.com/sschmid.png","language":"Objective-C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Gummi Reflection\n![Gummi Reflection Logo](http://sschmid.com/Libs/Gummi-Reflection/Gummi-Reflection-128.png)\n\n## Description\nGummi Reflection is a set of class methods to easily inspect objects in Objective-C. It's a small subproject mainly used by [Gummi Injection] and [Gummi Commander].\n\n## How to use Gummi Reflection\n\n#### Inspect an object\n\n```objective-c\nCar *car = [[Car alloc] init];\n\nBOOL isClass = [GRReflection isClass:car];\nBOOL isProtocol = [GRReflection isProtocol:car];\nBOOL isBlock = [GRReflection isBlock:car];\nBOOL isInstance = [GRReflection isInstance:car];\n\nNSLog(@\"isClass = %d\", isClass);        // NO\nNSLog(@\"isProtocol = %d\", isProtocol);  // NO\nNSLog(@\"isBlock = %d\", isBlock);        // NO\nNSLog(@\"isInstance = %d\", isInstance);  // YES\n```\n\n#### Get all property names of a class\n\n```objective-c\nNSArray *propertyNames = [GRReflection getAllPropertyNamesOfClass:[Car class]];\nNSLog(@\"propertyNames = %@\", propertyNames);  // [@\"wheel\", @\"engine\"]\n```\n\n#### Get the property type of a class\n\n```objective-c\n// returns class 'Wheel'\nid wheelType = [GRReflection getTypeForProperty:@\"wheel\"\n                                        ofClass:[Car class]];\n\n// returns protocol \u003cEngine\u003e\nid engineType = [GRReflection getTypeForProperty:@\"engine\"\n                                         ofClass:[Car class]];\n```\n\n## Install Gummi Reflection\nYou find the source files you need in Gummi-Reflection/Classes.\n\n## CocoaPods\nInstall [CocoaPods] and add the Gummi Reflection reference to your Podfile\n\n```\nplatform :ios, '5.0'\n  pod 'Gummi-Reflection'\nend\n```\n\n#### Add this remote\n\n```\n$ pod repo add sschmid-cocoapods-specs https://github.com/sschmid/cocoapods-specs\n```\n\n#### Install Gummi Reflection\n\n```\n$ cd path/to/project\n$ pod install\n```\n\nOpen the created Xcode Workspace file.\n\n## Projects that use Gummi Reflection\n* [Gummi Injection] - A lightweight dependency injection framework for Objective-C\n* [Gummi Commander] - Event Command Mapping System for Objective-C\n\n[CocoaPods]: http://cocoapods.org\n[Gummi Injection]: https://github.com/sschmid/Gummi-Injection\n[Gummi Commander]: https://github.com/sschmid/Gummi-Commander","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsschmid%2Fgummi-reflection","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsschmid%2Fgummi-reflection","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsschmid%2Fgummi-reflection/lists"}