Class: PM::GlobalNote

Inherits:
Note
  • Object
show all
Defined in:
lib/cocoapods-byte-panglem-beta/recorder.rb

Instance Attribute Summary collapse

Attributes inherited from Note

#auto_load, #auto_update, #load_detect

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Note

#get_update

Constructor Details

#initialize(auto_load = true, auto_update = PM::BuildConfig.update_value_last_version, load_detect = true, auto_load_whitelist = {}, is_release = false) ⇒ GlobalNote

Returns a new instance of GlobalNote.



128
129
130
131
132
133
134
# File 'lib/cocoapods-byte-panglem-beta/recorder.rb', line 128

def initialize(auto_load = true , auto_update = PM::BuildConfig.update_value_last_version, load_detect = true, auto_load_whitelist = {},is_release = false)
  @auto_load = auto_load
  @auto_update = get_update auto_update
  @load_detect = load_detect
  @auto_load_whitelist = auto_load_whitelist
  @is_release = is_release
end

Instance Attribute Details

#auto_load_whitelistObject

Returns the value of attribute auto_load_whitelist.



125
126
127
# File 'lib/cocoapods-byte-panglem-beta/recorder.rb', line 125

def auto_load_whitelist
  @auto_load_whitelist
end

#is_releaseObject (readonly)

Returns the value of attribute is_release.



127
128
129
# File 'lib/cocoapods-byte-panglem-beta/recorder.rb', line 127

def is_release
  @is_release
end

#use_service_localObject

Returns the value of attribute use_service_local.



126
127
128
# File 'lib/cocoapods-byte-panglem-beta/recorder.rb', line 126

def use_service_local
  @use_service_local
end

Class Method Details

.from_hash(hash) ⇒ Object



145
146
147
148
149
150
151
152
# File 'lib/cocoapods-byte-panglem-beta/recorder.rb', line 145

def self.from_hash(hash)
  global_note =  GlobalNote.new()
  global_note.auto_load = hash["AUTO_LOAD"] if hash.has_key?("AUTO_LOAD")
  global_note.auto_update = hash["AUTO_UPDATE"] if hash.has_key?("AUTO_UPDATE")
  global_note.load_detect = hash["LOAD_DETECT"] if hash.has_key?("LOAD_DETECT")
  global_note.auto_load_whitelist = hash["AUTO_LOAD_WHITELIST"] if hash.has_key?("AUTO_LOAD_WHITELIST")
  global_note
end

Instance Method Details

#to_hashObject



136
137
138
139
140
141
142
143
# File 'lib/cocoapods-byte-panglem-beta/recorder.rb', line 136

def to_hash
  hash = {}
  hash["AUTO_LOAD"] = @auto_load
  hash["AUTO_UPDATE"] = @auto_update
  hash["LOAD_DETECT"] = @load_detect
  hash["AUTO_LOAD_WHITELIST"] = @auto_load_whitelist
  hash
end