Module: Twitter

Extended by:
Config
Defined in:
lib/twitter.rb,
lib/twitter/base.rb,
lib/twitter/list.rb,
lib/twitter/size.rb,
lib/twitter/user.rb,
lib/twitter/error.rb,
lib/twitter/photo.rb,
lib/twitter/place.rb,
lib/twitter/point.rb,
lib/twitter/reply.rb,
lib/twitter/trend.rb,
lib/twitter/action.rb,
lib/twitter/client.rb,
lib/twitter/config.rb,
lib/twitter/cursor.rb,
lib/twitter/follow.rb,
lib/twitter/oembed.rb,
lib/twitter/status.rb,
lib/twitter/mention.rb,
lib/twitter/polygon.rb,
lib/twitter/request.rb,
lib/twitter/retweet.rb,
lib/twitter/version.rb,
lib/twitter/favorite.rb,
lib/twitter/language.rb,
lib/twitter/metadata.rb,
lib/twitter/settings.rb,
lib/twitter/creatable.rb,
lib/twitter/connection.rb,
lib/twitter/suggestion.rb,
lib/twitter/client/help.rb,
lib/twitter/client/urls.rb,
lib/twitter/geo_factory.rb,
lib/twitter/client/block.rb,
lib/twitter/client/legal.rb,
lib/twitter/client/lists.rb,
lib/twitter/client/users.rb,
lib/twitter/relationship.rb,
lib/twitter/saved_search.rb,
lib/twitter/client/search.rb,
lib/twitter/client/trends.rb,
lib/twitter/client/tweets.rb,
lib/twitter/configuration.rb,
lib/twitter/media_factory.rb,
lib/twitter/request/oauth.rb,
lib/twitter/action_factory.rb,
lib/twitter/direct_message.rb,
lib/twitter/authenticatable.rb,
lib/twitter/client/accounts.rb,
lib/twitter/client/activity.rb,
lib/twitter/error/forbidden.rb,
lib/twitter/error/not_found.rb,
lib/twitter/request/gateway.rb,
lib/twitter/request/phoenix.rb,
lib/twitter/client/favorites.rb,
lib/twitter/client/timelines.rb,
lib/twitter/error/bad_gateway.rb,
lib/twitter/error/bad_request.rb,
lib/twitter/list_member_added.rb,
lib/twitter/rate_limit_status.rb,
lib/twitter/error/client_error.rb,
lib/twitter/error/server_error.rb,
lib/twitter/error/unauthorized.rb,
lib/twitter/client/local_trends.rb,
lib/twitter/client/notification.rb,
lib/twitter/response/parse_json.rb,
lib/twitter/error/not_acceptable.rb,
lib/twitter/client/places_and_geo.rb,
lib/twitter/client/saved_searches.rb,
lib/twitter/client/spam_reporting.rb,
lib/twitter/client/direct_messages.rb,
lib/twitter/client/suggested_users.rb,
lib/twitter/error/enhance_your_calm.rb,
lib/twitter/error/service_unavailable.rb,
lib/twitter/error/internal_server_error.rb,
lib/twitter/request/multipart_with_file.rb,
lib/twitter/response/raise_client_error.rb,
lib/twitter/response/raise_server_error.rb,
lib/twitter/client/friends_and_followers.rb

Defined Under Namespace

Modules: Authenticatable, Config, Connection, Creatable, Request, Response Classes: Action, ActionFactory, Base, Client, Configuration, Cursor, DirectMessage, Error, Favorite, Follow, GeoFactory, Language, List, ListMemberAdded, MediaFactory, Mention, Metadata, OEmbed, Photo, Place, Point, Polygon, RateLimitStatus, Relationship, Reply, Retweet, SavedSearch, Settings, Size, Status, Suggestion, Trend, User, Version

Constant Summary

Constants included from Config

Config::DEFAULT_ADAPTER, Config::DEFAULT_CONNECTION_OPTIONS, Config::DEFAULT_CONSUMER_KEY, Config::DEFAULT_CONSUMER_SECRET, Config::DEFAULT_ENDPOINT, Config::DEFAULT_GATEWAY, Config::DEFAULT_MEDIA_ENDPOINT, Config::DEFAULT_OAUTH_TOKEN, Config::DEFAULT_OAUTH_TOKEN_SECRET, Config::DEFAULT_PROXY, Config::DEFAULT_SEARCH_ENDPOINT, Config::DEFAULT_USER_AGENT, Config::VALID_OPTIONS_KEYS

Class Method Summary collapse

Methods included from Config

configure, extended, options, reset

Class Method Details

.method_missing(method, *args, &block) ⇒ Object

Delegate to Twitter::Client


15
16
17
18
# File 'lib/twitter.rb', line 15

def method_missing(method, *args, &block)
  return super unless new.respond_to?(method)
  new.send(method, *args, &block)
end

.new(options = {}) ⇒ Twitter::Client

Alias for Twitter::Client.new

Returns:


10
11
12
# File 'lib/twitter.rb', line 10

def new(options={})
  Twitter::Client.new(options)
end

.respond_to?(method, include_private = false) ⇒ Boolean

Returns:

  • (Boolean)

20
21
22
# File 'lib/twitter.rb', line 20

def respond_to?(method, include_private=false)
  new.respond_to?(method, include_private) || super(method, include_private)
end