Class: StoreAgent::Guest

Inherits:
User
  • Object
show all
Defined in:
lib/store_agent/user.rb

Overview

ゲストユーザーはデフォルトの設定では何の権限も持たない

guest = StoreAgent::Guest.new
guest.workspace("ws").file("file.txt").read

Instance Attribute Summary

Attributes inherited from User

#identifiers

Instance Method Summary collapse

Methods inherited from User

#identifier, #identifier_array, #super_user?, #workspace

Methods included from Validator

#validates_to_be_excluded_slash!, #validates_to_be_not_guest_identifier!, #validates_to_be_not_nil_value!, #validates_to_be_not_superuser_identifier!, #validates_to_be_string_or_symbol!

Constructor Details

#initializeGuest

Returns a new instance of Guest.



103
104
105
# File 'lib/store_agent/user.rb', line 103

def initialize(*)
  @identifiers = [StoreAgent.config.guest_identifier]
end

Instance Method Details

#guest?Boolean

:nodoc:

Returns:

  • (Boolean)


107
108
109
# File 'lib/store_agent/user.rb', line 107

def guest? # :nodoc:
  true
end