class Fluent::GcloudPubSub::Message
Attributes
attributes[R]
message[R]
Public Class Methods
new(message, attributes = {})
click to toggle source
# File lib/fluent/plugin/gcloud_pubsub/client.rb, line 20 def initialize(message, attributes = {}) @message = message @attributes = attributes end
Public Instance Methods
bytesize()
click to toggle source
# File lib/fluent/plugin/gcloud_pubsub/client.rb, line 25 def bytesize attr_size = 0 @attributes.each do |key, val| attr_size += key.bytesize + val.bytesize end @message.bytesize + attr_size end