# Binary pattern matching when input is a stream

**URL:** <https://forum.elixirforum.com/t/binary-pattern-matching-when-input-is-a-stream/4286>\
**Category:** Questions\
**Created:** [March 24, 2017, 6:30pm UTC](https://forum.elixirforum.com/t/binary-pattern-matching-when-input-is-a-stream/4286 "2017-03-24T18:30:49Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![OvermindDL1](https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/overminddl1/32/2677_2.png) [@OvermindDL1](https://forum.elixirforum.com/u/OvermindDL1)\
**Post date:** [March 24, 2017, 7:46pm UTC](https://forum.elixirforum.com/t/binary-pattern-matching-when-input-is-a-stream/4286/6 "2017-03-24T19:46:18Z")

</div>

> [@Qqwy](#):
>
> You are probably looking for File.stream!(filename, , chunk\_size), which creates a stream that you can consume (and pattern match on) in the sizes of the given chunk.

Yep this if you know the chunk size, but how ‘dynamic’ is the parsing?

EDIT: Also, what are you doing with the data?

---

_[View the full topic](https://forum.elixirforum.com/t/binary-pattern-matching-when-input-is-a-stream/4286)._
