286 self.session = DBAPISession(None) |
286 self.session = DBAPISession(None) |
287 self.cnx = self.user = _NeedAuthAccessMock() |
287 self.cnx = self.user = _NeedAuthAccessMock() |
288 self.set_default_language(vreg) |
288 self.set_default_language(vreg) |
289 |
289 |
290 def get_option_value(self, option, foreid=None): |
290 def get_option_value(self, option, foreid=None): |
291 return self.cnx.get_option_value(option, foreid) |
291 if foreid is not None: |
|
292 warn('[3.19] foreid argument is deprecated', DeprecationWarning, |
|
293 stacklevel=2) |
|
294 return self.cnx.get_option_value(option) |
292 |
295 |
293 def set_session(self, session): |
296 def set_session(self, session): |
294 """method called by the session handler when the user is authenticated |
297 """method called by the session handler when the user is authenticated |
295 or an anonymous connection is open |
298 or an anonymous connection is open |
296 """ |
299 """ |
657 """Return the schema currently used by the repository.""" |
660 """Return the schema currently used by the repository.""" |
658 return self._repo.get_schema() |
661 return self._repo.get_schema() |
659 |
662 |
660 @check_not_closed |
663 @check_not_closed |
661 def get_option_value(self, option, foreid=None): |
664 def get_option_value(self, option, foreid=None): |
662 """Return the value for `option` in the configuration. If `foreid` is |
665 """Return the value for `option` in the configuration. |
663 specified, the actual repository to which this entity belongs is |
666 |
664 dereferenced and the option value retrieved from it. |
667 `foreid` argument is deprecated and now useless (as of 3.19). |
665 """ |
668 """ |
666 return self._repo.get_option_value(option, foreid) |
669 if foreid is not None: |
|
670 warn('[3.19] foreid argument is deprecated', DeprecationWarning, |
|
671 stacklevel=2) |
|
672 return self._repo.get_option_value(option) |
667 |
673 |
668 @check_not_closed |
674 @check_not_closed |
669 def describe(self, eid, asdict=False): |
675 def describe(self, eid, asdict=False): |
670 metas = self._repo.describe(self.sessionid, eid, **self._txid()) |
676 metas = self._repo.describe(self.sessionid, eid, **self._txid()) |
671 if len(metas) == 3: # backward compat |
677 if len(metas) == 3: # backward compat |