(argv)
| 150 | |
| 151 | |
| 152 | def main(argv): |
| 153 | # Authenticate and construct service. |
| 154 | service, flags = sample_tools.init( |
| 155 | argv, |
| 156 | "mapsengine", |
| 157 | "v1", |
| 158 | __doc__, |
| 159 | __file__, |
| 160 | parents=[argparser], |
| 161 | scope="https://www.googleapis.com/auth/mapsengine", |
| 162 | ) |
| 163 | |
| 164 | if flags.project_id: |
| 165 | # ListTables(service, flags.project_id) |
| 166 | # The example polygons shapefile should be in this directory. |
| 167 | filename = flags.shapefile or "polygons" |
| 168 | table_id = UploadShapefile(service, flags.project_id, filename) |
| 169 | logging.info("Sucessfully created table: %s", table_id) |
| 170 | else: |
| 171 | ListProjects(service) |
| 172 | return |
| 173 | |
| 174 | |
| 175 | if __name__ == "__main__": |
no test coverage detected
searching dependent graphs…