class FirefoxJson::Profiles::Profile

Collects methods to access a single profile's session file

Public Class Methods

new(data, ff_path) click to toggle source
# File lib/firefox-json/profiles.rb, line 9
def initialize(data, ff_path)
  @data = data
  @ff_path = ff_path
end

Public Instance Methods

path() click to toggle source
# File lib/firefox-json/profiles.rb, line 14
def path
  @path ||= @data['IsRelative'] == 1 ? File.join(@ff_path, @data['Path']) : @data['Path']
end
recovery_session() click to toggle source
# File lib/firefox-json/profiles.rb, line 22
def recovery_session
  Session.recovery(path)
end
session() click to toggle source
# File lib/firefox-json/profiles.rb, line 18
def session
  Session.default(path)
end