DALService

class pyvo.dal.DALService(baseurl, session=None)[source]

Bases: object

an abstract base class representing a DAL service located a particular endpoint.

instantiate the service connecting it to a base URL

Parameters:
baseurl : str

the base URL that should be used for forming queries to the service.

session : object

optional session to use for network requests

Attributes Summary

baseurl the base URL identifying the location of the service and where queries are submitted (read-only)

Methods Summary

create_query(self, **keywords) create a query object that constraints can be added to and then executed.
describe(self)
search(self, **keywords) send a search query to this service.

Attributes Documentation

baseurl

the base URL identifying the location of the service and where queries are submitted (read-only)

Methods Documentation

create_query(self, **keywords)[source]

create a query object that constraints can be added to and then executed.

Returns:
DALQuery

a generic query object

describe(self)[source]
search(self, **keywords)[source]

send a search query to this service.

This implementation has no knowledge of the type of service being queried. The query parameters are given as arbitrary keywords which will be assumed to be understood by the service (i.e. there is no argument checking). The response is a generic DALResults object.

Raises:
DALServiceError

for errors connecting to or communicating with the service

DALQueryError

for errors either in the input query syntax or other user errors detected by the service

DALFormatError

for errors parsing the VOTable response