Class: NATS::JetStream::API::StreamState
- Inherits:
-
Struct
- Object
- Struct
- NATS::JetStream::API::StreamState
- Defined in:
- lib/nats/io/js.rb
Overview
StreamState is the state of a stream.
Instance Attribute Summary collapse
- #bytes ⇒ Integer
- #consumer_count ⇒ Integer
- #first_seq ⇒ Integer
-
#first_ts ⇒ Object
Returns the value of attribute first_ts.
- #last_seq ⇒ Integer
-
#last_ts ⇒ Object
Returns the value of attribute last_ts.
- #messages ⇒ Integer
Instance Method Summary collapse
-
#initialize(opts = {}) ⇒ StreamState
constructor
A new instance of StreamState.
Constructor Details
#initialize(opts = {}) ⇒ StreamState
Returns a new instance of StreamState.
1375 1376 1377 1378 1379 |
# File 'lib/nats/io/js.rb', line 1375 def initialize(opts={}) rem = opts.keys - members opts.delete_if { |k| rem.include?(k) } super(opts) end |
Instance Attribute Details
#bytes ⇒ Integer
1372 1373 1374 1375 1376 1377 1378 1379 1380 |
# File 'lib/nats/io/js.rb', line 1372 StreamState = Struct.new(:messages, :bytes, :first_seq, :first_ts, :last_seq, :last_ts, :consumer_count, keyword_init: true) do def initialize(opts={}) rem = opts.keys - members opts.delete_if { |k| rem.include?(k) } super(opts) end end |
#consumer_count ⇒ Integer
1372 1373 1374 1375 1376 1377 1378 1379 1380 |
# File 'lib/nats/io/js.rb', line 1372 StreamState = Struct.new(:messages, :bytes, :first_seq, :first_ts, :last_seq, :last_ts, :consumer_count, keyword_init: true) do def initialize(opts={}) rem = opts.keys - members opts.delete_if { |k| rem.include?(k) } super(opts) end end |
#first_seq ⇒ Integer
1372 1373 1374 1375 1376 1377 1378 1379 1380 |
# File 'lib/nats/io/js.rb', line 1372 StreamState = Struct.new(:messages, :bytes, :first_seq, :first_ts, :last_seq, :last_ts, :consumer_count, keyword_init: true) do def initialize(opts={}) rem = opts.keys - members opts.delete_if { |k| rem.include?(k) } super(opts) end end |
#first_ts ⇒ Object
Returns the value of attribute first_ts
1372 1373 1374 |
# File 'lib/nats/io/js.rb', line 1372 def first_ts @first_ts end |
#last_seq ⇒ Integer
1372 1373 1374 1375 1376 1377 1378 1379 1380 |
# File 'lib/nats/io/js.rb', line 1372 StreamState = Struct.new(:messages, :bytes, :first_seq, :first_ts, :last_seq, :last_ts, :consumer_count, keyword_init: true) do def initialize(opts={}) rem = opts.keys - members opts.delete_if { |k| rem.include?(k) } super(opts) end end |
#last_ts ⇒ Object
Returns the value of attribute last_ts
1372 1373 1374 |
# File 'lib/nats/io/js.rb', line 1372 def last_ts @last_ts end |
#messages ⇒ Integer
1372 1373 1374 1375 1376 1377 1378 1379 1380 |
# File 'lib/nats/io/js.rb', line 1372 StreamState = Struct.new(:messages, :bytes, :first_seq, :first_ts, :last_seq, :last_ts, :consumer_count, keyword_init: true) do def initialize(opts={}) rem = opts.keys - members opts.delete_if { |k| rem.include?(k) } super(opts) end end |