class Qwik::QuickMLMember
Public Class Methods
new(config, site)
click to toggle source
# File vendor/qwik/lib/qwik/site-member.rb, line 87 def initialize(config, site) @config = config @site = site @str = nil @ar = [] check_new end
Private Class Methods
check_new_internal(str)
click to toggle source
# File vendor/qwik/lib/qwik/site-member.rb, line 128 def self.check_new_internal(str) ar = [] return ar if str.nil? str.each {|line| firstchar = line[0, 1] next if firstchar == '#' || firstchar == ';' k, v = line.chomp.split next if k.nil? ar << k } return ar end
Public Instance Methods
exist?(user)
click to toggle source
# File vendor/qwik/lib/qwik/site-member.rb, line 105 def exist?(user) list.include?(user) end
list()
click to toggle source
# File vendor/qwik/lib/qwik/site-member.rb, line 100 def list check_new @ar end
update_group_files()
click to toggle source
# File vendor/qwik/lib/qwik/site-member.rb, line 96 def update_group_files # @group_db.update_files end
Private Instance Methods
check_new()
click to toggle source
# File vendor/qwik/lib/qwik/site-member.rb, line 111 def check_new str = get_content return if str == @str @str = str @ar = QuickMLMember.check_new_internal(@str) end
get_content()
click to toggle source
# File vendor/qwik/lib/qwik/site-member.rb, line 118 def get_content f = @site.path+'_GroupMembers.txt' return f.read if f.exist? f = @site.path+',members' return f.read if f.exist? return nil end