Class: Bitly4R::SimpleClient

Inherits:
Client
  • Object
show all
Defined in:
lib/bitly4r/client.rb

Overview

Constructs a new ‘simple’ client.

Just like a standard Client, except that several methods are overridden to provide the ‘likely’ value, vs. a Response.

Instance Attribute Summary

Attributes inherited from Client

#token

Instance Method Summary collapse

Methods inherited from Client

#info, #initialize

Constructor Details

This class inherits a constructor from Bitly4R::Client

Instance Method Details

#expand(*args) ⇒ Object

Same as Client.expand, except that the long URL is returned (vs. a Response)



181
182
183
184
# File 'lib/bitly4r/client.rb', line 181

def expand(*args)
	#	just the default value, not the Response
	(super *args).to_s
end

#shorten(*args) ⇒ Object

Same as Client.shorten, except that the shortened URL is returned (vs. a Response)



176
177
178
# File 'lib/bitly4r/client.rb', line 176

def shorten(*args)
	(super *args).to_s
end