Class: PSGC::Import::Base
- Inherits:
-
Struct
- Object
- Struct
- PSGC::Import::Base
- Defined in:
- lib/psgc/import.rb
Overview
Base class for all other importers
Direct Known Subclasses
ImportMunicipalityBarangays, ImportProvinceMunicipalities, ImportRegionProvinces, ImportRegions
Constant Summary collapse
- WEB_FOLDER =
File.(File.join(%w(.. .. .. web)), __FILE__)
Class Attribute Summary collapse
-
.dir ⇒ Object
Returns the value of attribute dir.
-
.uri ⇒ Object
Returns the value of attribute uri.
Instance Attribute Summary collapse
-
#src ⇒ Object
Returns the value of attribute src.
Instance Method Summary collapse
-
#fetch ⇒ Object
Use ‘curl` to get the desired page.
-
#parse ⇒ Object
noop.
Class Attribute Details
.dir ⇒ Object
Returns the value of attribute dir.
14 15 16 |
# File 'lib/psgc/import.rb', line 14 def dir @dir end |
.uri ⇒ Object
Returns the value of attribute uri.
15 16 17 |
# File 'lib/psgc/import.rb', line 15 def uri @uri end |
Instance Attribute Details
#src ⇒ Object
Returns the value of attribute src
7 8 9 |
# File 'lib/psgc/import.rb', line 7 def src @src end |
Instance Method Details
#fetch ⇒ Object
Use ‘curl` to get the desired page
22 23 24 25 |
# File 'lib/psgc/import.rb', line 22 def fetch DownloadManager.fetch(src, target) parse end |
#parse ⇒ Object
noop
28 29 |
# File 'lib/psgc/import.rb', line 28 def parse end |