{"id":20381721,"url":"https://github.com/jacob-c-smith/queue","last_synced_at":"2025-08-19T11:08:38.736Z","repository":{"id":149625247,"uuid":"521044901","full_name":"Jacob-C-Smith/queue","owner":"Jacob-C-Smith","description":"A tested FIFO data structure implementation","archived":false,"fork":false,"pushed_at":"2024-07-26T02:31:08.000Z","size":50,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-04T22:36:20.967Z","etag":null,"topics":["c","queue","tested","thread-safe"],"latest_commit_sha":null,"homepage":"https://g10.app/status/#abstract_data_i","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/Jacob-C-Smith.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":"2022-08-03T22:03:16.000Z","updated_at":"2024-07-26T02:31:11.000Z","dependencies_parsed_at":"2023-07-21T21:31:50.339Z","dependency_job_id":"0df59106-cddb-4abf-8bd1-207bc13b4741","html_url":"https://github.com/Jacob-C-Smith/queue","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Jacob-C-Smith/queue","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Jacob-C-Smith%2Fqueue","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Jacob-C-Smith%2Fqueue/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Jacob-C-Smith%2Fqueue/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Jacob-C-Smith%2Fqueue/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Jacob-C-Smith","download_url":"https://codeload.github.com/Jacob-C-Smith/queue/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Jacob-C-Smith%2Fqueue/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":271143395,"owners_count":24706345,"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","status":"online","status_checked_at":"2025-08-19T02:00:09.176Z","response_time":63,"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":["c","queue","tested","thread-safe"],"created_at":"2024-11-15T02:15:05.284Z","updated_at":"2025-08-19T11:08:38.705Z","avatar_url":"https://github.com/Jacob-C-Smith.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# queue\n[![CMake](https://github.com/Jacob-C-Smith/queue/actions/workflows/cmake.yml/badge.svg)](https://github.com/Jacob-C-Smith/queue/actions/workflows/cmake.yml)\n\n**Dependencies:**\\\n[![sync](https://github.com/Jacob-C-Smith/sync/actions/workflows/cmake.yml/badge.svg)](https://github.com/Jacob-C-Smith/sync/actions/workflows/cmake.yml)\n[![CMake](https://github.com/Jacob-C-Smith/log/actions/workflows/cmake.yml/badge.svg)](https://github.com/Jacob-C-Smith/log/actions/workflows/cmake.yml)\n\n A minimal queue implementation written in C. \n \n \u003e 0 [Try it](#try-it)\n \u003e\n \u003e 1 [Download](#download)\n \u003e\n \u003e 2 [Build](#build)\n \u003e\n \u003e 3 [Example](#example)\n \u003e\n \u003e\u003e 3.1 [Example output](#example-output)\n \u003e\n \u003e 4 [Tester](#tester)\n \u003e\n \u003e 5 [Definitions](#definitions)\n \u003e\n \u003e\u003e 5.1 [Type definitions](#type-definitions)\n \u003e\u003e\n \u003e\u003e 5.2 [Function definitions](#function-definitions)\n\n## Try it\n[![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/Jacob-C-Smith/queue?quickstart=1)\n\nWait for a few moments, then click the play button on the bottom of the window. This will run the example program.\n\n ## Download\n To download queue, execute the following command\n ```bash\n $ git clone https://github.com/Jacob-C-Smith/queue\n ```\n ## Build\n To build on UNIX like machines, execute the following commands in the same directory\n ```bash\n $ cd queue\n $ cmake .\n $ make\n ```\n  This will build the example program, the tester program, and dynamic / shared libraries\n\n  To build queue for Windows machines, open the base directory in Visual Studio, and build your desired target(s)\n ## Example\n To run the example program, execute this command\n ```\n $ ./queue_example\n ```\n ### Example output\n ```\nFirst!\nSecond!\nThird!\n\nFourth!\nFifth!\nSixth!\nDetected queue underflow!\n ```\n [Source](main.c)\n## Tester\n To run the tester program, execute this command after building\n ```\n $ ./queue_test\n ```\n [Source](queue_test.c)\n ## Definitions\n ### Type definitions\n ```c\n typedef struct queue_s queue;\n ```\n ### Function definitions\n ```c \n// Allocaters\nDLLEXPORT int  queue_create        ( queue **pp_queue );\n\n// Constructors\nDLLEXPORT int  queue_construct     ( queue **pp_queue );\nDLLEXPORT int  queue_from_contents ( queue **pp_queue, void **pp_contents, size_t size );\n\n// Accessors\nDLLEXPORT int  queue_front         ( queue  *p_queue , void **pp_value );\nDLLEXPORT int  queue_rear          ( queue  *p_queue , void **pp_value );\nDLLEXPORT bool queue_empty         ( queue  *p_queue );\n\n// Mutators\nDLLEXPORT int  queue_enqueue       ( queue  *p_queue , void  *data );\nDLLEXPORT int  queue_dequeue       ( queue  *p_queue , void **pp_value );\n\n// Destructors\nDLLEXPORT int  queue_destroy       ( queue **pp_queue );\n ```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjacob-c-smith%2Fqueue","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjacob-c-smith%2Fqueue","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjacob-c-smith%2Fqueue/lists"}