Is this a pipeline? I have a class called Pipe and checking if this is what it actually is and not something else
(Every function call returns the the instance its held in)
A pipelined architecture refers to one with several distinct stages that are linked by some memory bus or transport mechanism. Also you have the concept of a producer/consumer there where stage B consumes what stage A produced and on down the line.
qpHalcy0n wrote:It does not appear so in this case.
A pipelined architecture refers to one with several distinct stages that are linked by some memory bus or transport mechanism. Also you have the concept of a producer/consumer there where stage B consumes what stage A produced and on down the line.
Thanks for the reply, there is a transport mechanism by using GetState() and SetState() each function can access and have the current state thus transporting data from one method to the other.
Looks more like a stream, really if you're just reading files and doing other little things to them. There would be several stages that each do different things. With that you usually have a stream of data that gets progressively modified by the different stages. In the classical sense, look at pipelined microarchitecture. Fetch, decode, execute, write. 4-stage pipeline. Stream of data comes in (instructions/operands) and they are progressively analyzed and modified until they come out the other side. Like building a car in a factory with a single conveyer belt. Raw materials go in...each stage modifies....car comes out.
qpHalcy0n wrote:Myehhhh -_- ...no, still not seeing it that way.
Looks more like a stream, really if you're just reading files and doing other little things to them. There would be several stages that each do different things. With that you usually have a stream of data that gets progressively modified by the different stages. In the classical sense, look at pipelined microarchitecture. Fetch, decode, execute, write. 4-stage pipeline. Stream of data comes in (instructions/operands) and they are progressively analyzed and modified until they come out the other side. Like building a car in a factory with a single conveyer belt. Raw materials go in...each stage modifies....car comes out.
Querying data isn't really a "pipeline".
Thanks for the advice
My usage of that class isn't just for streams, but it will be used for more complicated stuff later on (like rendering pipelines and script analysis)
Well, rendering IS a pipeline because you have a stream of data coming in and it is progressively modified by multiple units until you get some different output. However, simply having two units that both produce and consume isn't a pipeline at all. I'm not giving advice really...this is just....what that is.
The first command reads file "myfile" and feeds its content to the second, which filters only the lines with the text "sometext". The third reads these filtered lines and replaces all ":" with spaces and the fourth splits these lines by spaces and prints only the first field. What characterizes the pipeline is that each operation acts (only) on the results of the previous, and you feed this "black box" with some input (the content of the file) and it outputs processed information. I hope this makes things a little bit more clear.
That's actually a really useful example. Though I've known what the pipe character is and does for a long time, I've never compared it something like a graphics pipeline.
Falco Girgis wrote:It is imperative that I can broadcast my narcissistic commit strings to the Twitter! Tweet Tweet, bitches!