Class: DropboxApi::Metadata::AddMember

Inherits:
Base
  • Object
show all
Defined in:
lib/dropbox_api/metadata/add_member.rb

Overview

Examples of serialized AddMember objects:

{
  "member": {
    ".tag": "email",
    "email": "[email protected]"
  },
  "access_level": {
    ".tag": "editor"
  }
},
{
  "member": {
    ".tag": "dropbox_id",
    "dropbox_id": "dbid:AAEufNrMPSPe0dMQijRP0N_aZtBJRm26W4Q"
  },
  "access_level": {
    ".tag": "viewer"
  }
}

Class Method Summary collapse

Methods inherited from Base

field, #initialize, #serialized_field, #to_hash

Constructor Details

This class inherits a constructor from DropboxApi::Metadata::Base

Class Method Details

.build_from_string(member, access_level = :editor) ⇒ Object


26
27
28
29
30
31
# File 'lib/dropbox_api/metadata/add_member.rb', line 26

def build_from_string(member, access_level = :editor)
  new({
    "member" => Member.new(member),
    "access_level" => access_level
  })
end