Module: MediaWiki::Query::Lists::Log::NewUsers

Included in:
MediaWiki::Query::Lists::Log
Defined in:
lib/mediawiki/query/lists/log/newusers.rb

Instance Method Summary collapse

Instance Method Details

#get_autocreate_users_log(user = nil, title = nil, start = nil, stop = nil, limit = @query_limit_default) ⇒ Array<Hash>

Gets newusers/autocreate logs.

Parameters:

Returns:

  • (Array<Hash>)

    The events, containing the following keys: id, new_user, user, comment, timestamp.

See Also:

Since:

  • 0.10.0



11
12
13
14
15
16
17
18
19
20
21
# File 'lib/mediawiki/query/lists/log/newusers.rb', line 11

def get_autocreate_users_log(user = nil, title = nil, start = nil, stop = nil, limit = @query_limit_default)
  response = get_log('newusers/autocreate', user, title, start, stop,
                     limit)

  ret = []
  response['query']['logevents'].each do |log|
    ret << loghash_user(log)
  end

  ret
end

#get_user_create2_log(user = nil, title = nil, start = nil, stop = nil, limit = @query_limit_default) ⇒ Array<Hash>

Gets newusers/create2, when one user creates another user, logs.

Parameters:

Returns:

  • (Array<Hash>)

    The events, containing the following keys: id, title, new_user, user, comment, timestamp.

See Also:

Since:

  • 0.10.0



29
30
31
32
33
34
35
36
37
38
# File 'lib/mediawiki/query/lists/log/newusers.rb', line 29

def get_user_create2_log(user = nil, title = nil, start = nil, stop = nil, limit = @query_limit_default)
  resp = get_log('newusers/create2', user, title, start, stop, limit)

  ret = []
  resp['query']['logevents'].each do |log|
    ret << loghash_user(log)
  end

  ret
end

#get_user_create_log(user = nil, title = nil, start = nil, stop = nil, limit = @query_limit_default) ⇒ Array<Hash>

Gets newusers/create, when one user creates their own account, logs.

Parameters:

Returns:

  • (Array<Hash>)

    The events, containing the following keys: id, title, user, comment, timestamp.

See Also:

Since:

  • 0.10.0



45
46
47
48
49
50
51
52
53
54
# File 'lib/mediawiki/query/lists/log/newusers.rb', line 45

def get_user_create_log(user = nil, title = nil, start = nil, stop = nil, limit = @query_limit_default)
  resp = get_log('newusers/create', user, title, start, stop, limit)

  ret = []
  resp['query']['logevents'].each do |log|
    ret << loghash_user(log)
  end

  ret
end