Skip to content

Commit

Permalink
language: document HasEnvironment.dbs
Browse files Browse the repository at this point in the history
  • Loading branch information
sbourdeauducq committed Aug 22, 2015
1 parent d38f1e6 commit 72616f6
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions artiq/language/environment.py
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,15 @@ def build(self):
raise NotImplementedError

def dbs(self):
"""Returns the device manager, the parameter database and the result
database, in this order.
This is the same order that the constructor takes them, allowing
sub-objects to be created with this idiom to pass the environment
around: ::
sub_object = SomeLibrary(*self.dbs())
"""
return self.__dmgr, self.__pdb, self.__rdb

def get_argument(self, key, processor=None):
Expand Down

0 comments on commit 72616f6

Please sign in to comment.