{"id":37030261,"url":"https://github.com/fernandodev/daggerplay","last_synced_at":"2026-01-14T03:41:18.305Z","repository":{"id":30411914,"uuid":"33964769","full_name":"fernandodev/daggerplay","owner":"fernandodev","description":"DaggerPlay provides to you a easy implementation way to use Dagger injection by Square","archived":false,"fork":false,"pushed_at":"2018-04-20T21:22:00.000Z","size":79,"stargazers_count":11,"open_issues_count":3,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2023-07-15T22:03:12.208Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/fernandodev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-04-15T00:48:27.000Z","updated_at":"2023-07-15T22:03:12.209Z","dependencies_parsed_at":"2022-09-22T06:50:28.307Z","dependency_job_id":null,"html_url":"https://github.com/fernandodev/daggerplay","commit_stats":null,"previous_names":[],"tags_count":1,"template":null,"template_full_name":null,"purl":"pkg:github/fernandodev/daggerplay","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fernandodev%2Fdaggerplay","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fernandodev%2Fdaggerplay/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fernandodev%2Fdaggerplay/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fernandodev%2Fdaggerplay/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fernandodev","download_url":"https://codeload.github.com/fernandodev/daggerplay/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fernandodev%2Fdaggerplay/sbom","scorecard":{"id":397426,"data":{"date":"2025-08-11","repo":{"name":"github.com/fernandodev/daggerplay","commit":"cb4b63cd9e90f1a2d0396407f472d8364ed34a13"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2.5,"checks":[{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Binary-Artifacts","score":9,"reason":"binaries present in source code","details":["Warn: binary detected: gradle/wrapper/gradle-wrapper.jar:1"],"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Code-Review","score":0,"reason":"Found 0/7 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"License","score":0,"reason":"license file not detected","details":["Warn: project does not have a license file"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}}]},"last_synced_at":"2025-08-18T19:21:57.162Z","repository_id":30411914,"created_at":"2025-08-18T19:21:57.162Z","updated_at":"2025-08-18T19:21:57.162Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28408854,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T01:52:23.358Z","status":"online","status_checked_at":"2026-01-14T02:00:06.678Z","response_time":107,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":"2026-01-14T03:41:17.772Z","updated_at":"2026-01-14T03:41:18.289Z","avatar_url":"https://github.com/fernandodev.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"Dagger Play\n==\n\nDagger Play is a small set of reusable classes for [Dagger](https://github.com/square/dagger) injection. There many ways to implement Dagger into your project. Unfortunately memory leaks can occur easily if you implement it without attention.\n\nDagger Play just do the \"step by step\" for you and provides a minimum and necessary interface to inject and install Dagger into your project. So forget those tutorials and a lot of poor code snippets and start injecting!\n\n- [Dagger Play](#dagger-play)\n  - [Installation](#installation)\n  - [Using](#using)\n  - [Important Details](#important-details)\n    - [@WithActivity \u0026 @WithApplication](#@withactivity-\u0026-@withapplication)\n    - [Default Injections](#default-injections)\n  - [License](#license)\n\n## Installation\n\nIt's very simple with gradle ;)\n\nAdd `mavenCentral` as repository source:\n\n```gradle\nrepositories {\n  mavenCentral()\n}\n```\n\nAnd finnaly add this line inside `dependencies { }` section:\n\n```gradle\ncompile 'com.github.fernandodev.daggerplay:daggerplay:+'\n```\n\nThe `+` symbol indicates to gradle to get the latest version.\n\n* See the sample if there are any doubts.\n* DaggerPlay uses compile 'dagger:1.2.+' and 'dagger-compiler:1.2.+'\n\n## Using\n\nLike Dagger, you need to create a Module for your Android Project. Generally \u003cAppName\u003eModule. See the sample below:\n\n```java\n@Module(\n    injects = {\n        MainActivity.class    //THE INJECTABLE CLASSES\n    },\n    library = true,\n    complete = false,\n    overrides = false\n)\npublic class SampleModule {\n\n  @Provides UsefulHelper provideUsefulHelper(@WithActivity Context context) {\n    return new UsefulHelper(context);\n  }\n}\n```\n\nNow, you have your main module [(you can create how many modules as you want)](http://square.github.io/dagger/), so you need to register it\nand finally install Dagger into your application.\n\nExtends android.app.Application and in `onCreate` just register your module and install Dagger.\n\n```java\npublic class Samplepplication extends Application {\n\n  @Override\n  public void onCreate() {\n    super.onCreate();\n    DaggerPlay.registerModules(new SampleModule());\n    DaggerPlay.install(this);\n  }\n}\n```\n\n* Call install after register all your modules.\n\nNow you are ready to use your injections!\n\nThere are special methods in DaggerPlay class for `Activity`, `Fragment`, `Support Fragment` and `IntentService` injections.\n\n```java\npublic static void injectActivity(Activity activity);\n\npublic static void injectFragment(Activity activity, Fragment fragment);\n\npublic static void injectSupportFragment(Activity activity, android.support.v4.app.Fragment fragment);\n\npublic static void injectService(IntentService service);\n```\n\nSo, in `onCreate` callback, just call `DaggerPlay.injectActivity(this);` and everything will work like a charm.\n\n## Important Details\n\n### @WithActivity \u0026 @WithApplication\n\nThis is a especial annotation to distinguish `Context` provided by Application or Activity. So, if you want a `Context` from `Activity` use this annotation.\n\n### Default Injections\n\nWith DaggerPlay you get default injections for your application\n\n1. `@Inject @WithActivity Context`\n2. `@Inject Resources`\n3. `@Inject Application`\n4. `@Inject Activity`\n5. `@Inject @WithApplication Context`\n\n## License\n\nThe MIT License (MIT)\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in\nall copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\nTHE SOFTWARE.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffernandodev%2Fdaggerplay","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffernandodev%2Fdaggerplay","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffernandodev%2Fdaggerplay/lists"}