Class: CompaniesHouse::Request
- Inherits:
-
Object
- Object
- CompaniesHouse::Request
- Defined in:
- lib/companies_house/request.rb
Constant Summary collapse
- BASE_URI =
'http://data.companieshouse.gov.uk/doc/company/'
- ALLOWED_PREFIXES =
White list of allowed prefixes for companies house numbers. 1st line is English and Welsh prefixes 2nd line is Scottish prefixes 3rd line is Northen Irish prefixes dd is the default prefix in regex notation.
%w(AC BR FC GE IP LP OC RC SE ZC SC SA SF SL SZ SP SO SR NI NA NF NL NZ NP NO NR \d\d)
Instance Method Summary collapse
-
#initialize(registration_number) ⇒ Request
constructor
Don’t call this directly.
- #perform ⇒ Object
Constructor Details
#initialize(registration_number) ⇒ Request
Don’t call this directly. Instead, use CompaniesHouse.lookup “01234567”
18 19 20 |
# File 'lib/companies_house/request.rb', line 18 def initialize(registration_number) @registration_number = validate(registration_number) end |