aggregator.pumproom.faucet¶
-
class
aggregator.pumproom.faucet.Faucet(task, *args, **kwargs)[source]¶ Bases:
ambassador.transport.Transport-
endpoint¶ Pipe
-
emissary¶ Plumber
-
user¶ AppUser
-
cargo¶ Cargo
-
record¶ Invoice
-
task¶ str
-
create_record(stamp, obj)[source]¶ Create a record of the response
Parameters: - stamp (
Stamp) – - obj (
ReservoirQuery) –
Returns: Return type: - stamp (
-
is_obsolete()[source]¶ Returns a Boolean indicating whether a more recent call has been made to the same endpoint with the same credentials.
-
process_request(obj)[source]¶ Parameters: obj ( ReservoirQuery) –Returns: Return type: CargoTakes an a ReservoirQuery, formats and submits it to the API, returns a Cargo object. This method needs to be implemented in derived classes so it can be customized for specific APIs.
-