{
  "canonical_url": "https://crates.flyology.org/community/",
  "catalog": {
    "name": "community",
    "repository_url": "https://github.com/alire-project/alire-index",
    "revision": "cd12c6aa35b7d6483841517305d57ba167ec78d0"
  },
  "generated_at": "2026-08-23T04:55:42Z",
  "index": {
    "version": "1.4.0"
  },
  "package": {
    "catalog": "community",
    "description": "Provides a Root_Stream_Type wrapper over an array of octets in memory.",
    "development_only": false,
    "latest_version": "1.1.0",
    "name": "octet_memory_stream",
    "selected_version": "1.1.0",
    "versions": [
      {
        "dependants": [],
        "dependencies": [],
        "development": false,
        "external": false,
        "manifest": {
          "authors": [
            "Miko Elbrecht"
          ],
          "description": "Provides a Root_Stream_Type wrapper over an array of octets in memory.",
          "licenses": "Apache-2.0 WITH LLVM-exception",
          "long-description": "`octet_memory_stream` provides a standalone `Ada.Streams.Root_Stream_Type`\nwrapper around an `Octet_Array` (array of 8-bit bytes,) primarily for the\npurpose of protecting an over-arching stream from misalignment while reading\nfrom, or writing to, e.g., a file format.\n\nIf the `Memory_Stream` detects an out-of-bounds error as the result of a read\nor write operation, an `Out_Of_Bounds_Error` exception will be raised.\n\nExample Use\n-----------\nAll pertinent types and subprograms are available within the package \n`Octet_Memory_Stream`. Wrapping an `Octet_Array` is done through the\n`To_Stream` function.\n```ada\npragma Ada_2022;\n\nwith Ada.Text_IO;\nwith Ada.Streams.Stream_IO;\nuse  Ada.Streams.Stream_IO;\nwith Octet_Memory_Stream;\n\nprocedure TestDemo is\n   F                : File_Type;\n   Protected_Stream : Stream_Access;\n   Memory_Stream    : Octet_Memory_Stream.Stream_Access;\nbegin\n   Open (F, In_File, \"example\");\n   Protected_Stream := Stream (F);\n   declare\n      Data : Octet_Memory_Stream.Octet_Array (1 .. 50);\n   begin\n      Octet_Memory_Stream.Octet_Array'Read (Protected_Stream, Data);\n      Memory_Stream := Octet_Memory_Stream.To_Stream (Data);\n   end;\n   declare\n      OK_Data  : Octet_Memory_Stream.Octet_Array (1 .. 25);\n      OOB_Data : Octet_Memory_Stream.Octet_Array (1 .. 26);\n   begin\n      Octet_Memory_Stream.Octet_Array'Read (Memory_Stream, OK_Data);\n      Ada.Text_IO.Put_Line (OK_Data'Image);\n\n      Octet_Memory_Stream.Octet_Array'Read (Memory_Stream, OOB_Data);\n      --  exception raised above\n      Ada.Text_IO.Put_Line (OOB_Data'Image);\n   end;\n   Close (F);\nend TestDemo;\n```\n",
          "maintainers": [
            "Miko Elbrecht <pmt.mailservice@gmail.com>"
          ],
          "maintainers-logins": [
            "ATPStorages"
          ],
          "name": "octet_memory_stream",
          "origin": {
            "commit": "54ecee472e8f78ab6d09df59f48bcca548364ee3",
            "url": "git+https://github.com/Bread-Experts-Group/octet_memory_stream.git"
          },
          "tags": [
            "octet",
            "byte",
            "buffer",
            "stream",
            "ada",
            "streams",
            "memory"
          ],
          "version": "1.1.0",
          "website": "https://github.com/Bread-Experts-Group/octet_memory_stream"
        },
        "path": "index/oc/octet_memory_stream/octet_memory_stream-1.1.0.toml",
        "version": "1.1.0"
      },
      {
        "dependants": [],
        "dependencies": [],
        "development": false,
        "external": false,
        "manifest": {
          "authors": [
            "Miko Elbrecht"
          ],
          "description": "Provides a Root_Stream_Type wrapper over an array of octets in memory.",
          "licenses": "Apache-2.0 WITH LLVM-exception",
          "long-description": "`octet_memory_stream` provides a standalone `Ada.Streams.Root_Stream_Type`\nwrapper around an `Octet_Array` (array of 8-bit bytes,) primarily for the\npurpose of protecting an over-arching stream from misalignment while reading\nfrom, or writing to, e.g., a file format.\n\nIf the `Memory_Stream` detects an out-of-bounds error as the result of a read\nor write operation, an `Out_Of_Bounds_Error` exception will be raised.\n\n**NOTE:** This crate does not currently support writing from a `Memory_Stream`,\nhowever this is a priority and will be done so in update 1.1.0.\n\nExample Use\n-----------\nAll pertinent types and subprograms are available within the package \n`Octet_Memory_Stream`. Wrapping an `Octet_Array` is done through the\n`To_Stream` function.\n```ada\npragma Ada_2022;\n\nwith Ada.Text_IO;\nwith Ada.Streams.Stream_IO;\nuse  Ada.Streams.Stream_IO;\nwith Octet_Memory_Stream;\n\nprocedure TestDemo is\n   F                : File_Type;\n   Protected_Stream : Stream_Access;\n   Memory_Stream    : Octet_Memory_Stream.Stream_Access;\nbegin\n   Open (F, In_File, \"example\");\n   Protected_Stream := Stream (F);\n   declare\n      Data : Octet_Memory_Stream.Octet_Array (1 .. 50);\n   begin\n      Octet_Memory_Stream.Octet_Array'Read (Protected_Stream, Data);\n      Memory_Stream := Octet_Memory_Stream.To_Stream (Data);\n   end;\n   declare\n      OK_Data  : Octet_Memory_Stream.Octet_Array (1 .. 25);\n      OOB_Data : Octet_Memory_Stream.Octet_Array (1 .. 26);\n   begin\n      Octet_Memory_Stream.Octet_Array'Read (Memory_Stream, OK_Data);\n      Ada.Text_IO.Put_Line (OK_Data'Image);\n\n      Octet_Memory_Stream.Octet_Array'Read (Memory_Stream, OOB_Data);\n      --  exception raised above\n      Ada.Text_IO.Put_Line (OOB_Data'Image);\n   end;\n   Close (F);\nend TestDemo;\n```\n",
          "maintainers": [
            "Miko Elbrecht <pmt.mailservice@gmail.com>"
          ],
          "maintainers-logins": [
            "ATPStorages"
          ],
          "name": "octet_memory_stream",
          "origin": {
            "commit": "73fcfb370f5763630e8ccb72457d43018daa01d9",
            "url": "git+https://github.com/Bread-Experts-Group/octet_memory_stream.git"
          },
          "tags": [
            "octet",
            "byte",
            "buffer",
            "stream",
            "ada",
            "streams",
            "memory"
          ],
          "version": "1.0.0",
          "website": "https://github.com/Bread-Experts-Group/octet_memory_stream"
        },
        "path": "index/oc/octet_memory_stream/octet_memory_stream-1.0.0.toml",
        "version": "1.0.0"
      }
    ]
  },
  "schema_version": 4
}
