Module: Meminator
- Extended by:
- Meminator
- Included in:
- Meminator
- Defined in:
- lib/meminator.rb,
lib/meminator/auth.rb,
lib/meminator/auth.rb,
lib/meminator/list.rb,
lib/meminator/user_agent.rb
Overview
Defined Under Namespace
Classes: Error, List, Meminator, NotAuthorized
Constant Summary
collapse
- VERSION =
'0.0.6'
- GENERATOR_URL =
'http://version1.api.memegenerator.net/Instance_Create'
- DISPLAY_URL =
'http://cdn.memegenerator.net'
- @@username =
nil
- @@password =
nil
- @@useragent =
"meminator/#{VERSION} Ruby/#{RUBY_VERSION}"
Instance Method Summary
collapse
Instance Method Details
#password ⇒ Object
15
16
17
18
19
20
21
|
# File 'lib/meminator/auth.rb', line 15
def password
if @@password
@@password
else
raise NotAuthorized
end
end
|
#password=(pword) ⇒ Object
27
28
29
|
# File 'lib/meminator/auth.rb', line 27
def password=(pword)
@@password = pword
end
|
#user_agent ⇒ Object
5
6
7
|
# File 'lib/meminator/user_agent.rb', line 5
def user_agent
@@useragent
end
|
#user_agent=(agent) ⇒ Object
9
10
11
|
# File 'lib/meminator/user_agent.rb', line 9
def user_agent=(agent)
@@useragent = agent
end
|
#username ⇒ Object
7
8
9
10
11
12
13
|
# File 'lib/meminator/auth.rb', line 7
def username
if @@username
@@username
else
raise NotAuthorized
end
end
|
#username=(uname) ⇒ Object
23
24
25
|
# File 'lib/meminator/auth.rb', line 23
def username=(uname)
@@username = uname
end
|