{"id":15497479,"url":"https://github.com/heapwolf/cxx-eventemitter","last_synced_at":"2025-04-22T22:16:14.206Z","repository":{"id":66203334,"uuid":"20425788","full_name":"heapwolf/cxx-eventemitter","owner":"heapwolf","description":"A minimalist event emitter for C++","archived":false,"fork":false,"pushed_at":"2019-04-13T13:12:48.000Z","size":244,"stargazers_count":33,"open_issues_count":0,"forks_count":7,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-01-08T16:30:48.303Z","etag":null,"topics":["event-emitter","eventemitter"],"latest_commit_sha":null,"homepage":"","language":"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/heapwolf.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2014-06-03T01:30:59.000Z","updated_at":"2024-08-14T09:40:45.000Z","dependencies_parsed_at":"2023-03-01T09:30:53.258Z","dependency_job_id":null,"html_url":"https://github.com/heapwolf/cxx-eventemitter","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heapwolf%2Fcxx-eventemitter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heapwolf%2Fcxx-eventemitter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heapwolf%2Fcxx-eventemitter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heapwolf%2Fcxx-eventemitter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/heapwolf","download_url":"https://codeload.github.com/heapwolf/cxx-eventemitter/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":233665636,"owners_count":18710919,"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":["event-emitter","eventemitter"],"created_at":"2024-10-02T08:38:26.989Z","updated_at":"2025-01-12T22:09:31.438Z","avatar_url":"https://github.com/heapwolf.png","language":"C++","funding_links":[],"categories":["C++"],"sub_categories":[],"readme":"# SYNOPSIS\nA minimalist event emitter for `C++`.\n\n# DESCRIPTION\nThis emitter allows you to emit and receive arbitrary/variadic paramaters of \nequal type. Captures are also allowed.\n\n# EXAMPLE\n\n```c++\n#include \"deps/datcxx/cxx-eventemitter/index.h\"\n\nint main() {\n\n  EventEmitter ee;\n\n  ee.on(\"hello\", [\u0026](string name, int num) {\n    // ...do something with the values.\n  });\n\n  ee.emit(\"hello\", \"beautiful\", 100);\n}\n```\n\n# USAGE\nThis module is designed to work with the [`datcxx`][0] build tool. To add this\nmodule to your project us the following command...\n\n```bash\nbuild add datcxx/cxx-eventemitter\n```\n\n# TEST\n\n```bash\nbuild run test\n```\n\n# API\n\n## INSTANCE METHODS\n\n### `void` on(string eventName, lambda callback);\nListen for an event multiple times.\n\n### `void` once(string eventName, lambda callback);\nListen for an event once.\n\n### `void` emit(string eventName [, arg1 [, arg2...]]);\nEmit data for a particular event.\n\n### `void` off(string eventName);\nRemove listener for a particular event.\n\n### `void` off();\nRemove all listeners on the emitter.\n\n### `int` listeners();\nNumber of listeners an emitter has.\n\n## INSTANCE MEMBERS\n\n### maxListeners\nNumber of listeners an event emitter should have\nbefore considering that there is a memory leak.\n\n[0]:https://github.com/datcxx/build\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fheapwolf%2Fcxx-eventemitter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fheapwolf%2Fcxx-eventemitter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fheapwolf%2Fcxx-eventemitter/lists"}