Sha256: ad3f9f21e58f2a536c2ea59fe37f79d3eb7615866d69f0d45843032aef322630

Contents?: true

Size: 1.1 KB

Versions: 11

Compression:

Stored size: 1.1 KB

Contents

# frozen_string_literal: true

module DjiMqttConnect
  module Thing::Product
    # https://developer.dji.com/doc/cloud-api-tutorial/en/server-api-reference/mqtt/thing-model/gateway/dock/organization.html#search-for-the-organization-information-that-device-bound-to
    class AirportOrganizationGetRequestsReplyMessage < Message
      def self.build_for(airport_organization_get_message, output:, result: 0)
        new(
          _method: airport_organization_get_message._method,
          tid: airport_organization_get_message.tid,
          bid: airport_organization_get_message.bid,
          timestamp: Time.now.strftime("%s%L").to_i,
          data: {
            result: result,
            output: output
          }
        )
      end

      attribute :tid, Types::UUID
      attribute :bid, Types::UUID
      attribute :timestamp, Types::Timestamp

      attribute :_method, Types::String.enum("airport_organization_get")

      attribute :data do
        attribute :result, Types::Integer
        attribute :output do
          attribute :organization_name, Types::String
        end
      end
    end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
dji_mqtt_connect-0.1.11 lib/dji_mqtt_connect/messages/thing/product/airport_organization_get_requests_reply_message.rb
dji_mqtt_connect-0.1.10 lib/dji_mqtt_connect/messages/thing/product/airport_organization_get_requests_reply_message.rb
dji_mqtt_connect-0.1.9 lib/dji_mqtt_connect/messages/thing/product/airport_organization_get_requests_reply_message.rb
dji_mqtt_connect-0.1.8 lib/dji_mqtt_connect/messages/thing/product/airport_organization_get_requests_reply_message.rb
dji_mqtt_connect-0.1.7 lib/dji_mqtt_connect/messages/thing/product/airport_organization_get_requests_reply_message.rb
dji_mqtt_connect-0.1.6 lib/dji_mqtt_connect/messages/thing/product/airport_organization_get_requests_reply_message.rb
dji_mqtt_connect-0.1.5 lib/dji_mqtt_connect/messages/thing/product/airport_organization_get_requests_reply_message.rb
dji_mqtt_connect-0.1.4.1 lib/dji_mqtt_connect/messages/thing/product/airport_organization_get_requests_reply_message.rb
dji_mqtt_connect-0.1.4 lib/dji_mqtt_connect/messages/thing/product/airport_organization_get_requests_reply_message.rb
dji_mqtt_connect-0.1.3 lib/dji_mqtt_connect/messages/thing/product/airport_organization_get_requests_reply_message.rb
dji_mqtt_connect-0.1.2 lib/dji_mqtt_connect/messages/thing/product/airport_organization_get_requests_reply_message.rb