Class: XTwitterScraper::Models::XGetArticleResponse

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/x_twitter_scraper/models/x_get_article_response.rb,
sig/x_twitter_scraper/models/x_get_article_response.rbs

Overview

See Also:

  • XTwitterScraper::Resources::X#get_article

Defined Under Namespace

Classes: Article, Author

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(length: nil, offset: nil, style: nil) ⇒ Object

Parameters:

  • length (Integer) (defaults to: nil)
  • offset (Integer) (defaults to: nil)
  • style (String) (defaults to: nil)


# File 'lib/x_twitter_scraper/models/x_get_article_response.rb', line 18

Instance Attribute Details

#articleXTwitterScraper::Models::XGetArticleResponse::Article



10
# File 'lib/x_twitter_scraper/models/x_get_article_response.rb', line 10

required :article, -> { XTwitterScraper::Models::XGetArticleResponse::Article }

#authorXTwitterScraper::Models::XGetArticleResponse::Author?

X Article author profile fields returned when available.



16
# File 'lib/x_twitter_scraper/models/x_get_article_response.rb', line 16

optional :author, -> { XTwitterScraper::Models::XGetArticleResponse::Author }

Instance Method Details

#to_hash{

Returns:

  • ({)


23
# File 'sig/x_twitter_scraper/models/x_get_article_response.rbs', line 23

def to_hash: -> {