Logo Search packages:      
Sourcecode: ubuntu-sso-client version File versions  Download package

def ubuntu_sso::main::LoginProcessor::__get_option (   self,
  realm,
  option 
) [private]

Return a specific option for that realm in
   the config file. If the realm does not exist in the config file,
   fall back to the [default] section.

Definition at line 191 of file main.py.

00191                                          :
        """Return a specific option for that realm in
           the config file. If the realm does not exist in the config file,
           fall back to the [default] section."""
        if self.config.has_section(realm) and \
           self.config.has_option(realm, option):
            urlstub = self.config.get(realm, option)
            return urlstub

        # either the realm exists and this url does not, or
        # the realm doesn't exist; either way, fall back to [default] section
        urlstub = self.config.get("default", option, None)
        if urlstub is not None:
            return urlstub

        # this url does not exist in default section either
        # this shouldn't happen
        raise NoDefaultConfigError("No default configuration for %s" % option)


class Login(dbus.service.Object):


Generated by  Doxygen 1.6.0   Back to index