@classmethod
  def DefineSessionType(cls, name, prefix):
    sane_name = name[0].upper() + name[1:].lower()
    setattr(
        cls, 'SESSION_TYPE_PREFIX_%s' % name.upper(), '%s_' % prefix)
    setattr(
        cls, 'Set%s' % sane_name,
        lambda self, k, data=None, **kwargs: self.Set(
            '%s_%s' % (prefix, k), data, **kwargs))
    setattr(
        cls, 'Get%s' % sane_name,
        lambda self, k: self.Get('%s_%s' % (prefix, k)))
    setattr(
        cls, 'Del%s' % sane_name,
        lambda self, k: self.DeleteById('%s_%s' % (prefix, k)))
See parent class documentation
dataset/ETHPy150Open google/simian/src/simian/auth/base.py/AuthSessionBase.DefineSessionType--crossover with--dataset/ETHPy150Open AppScale/appscale/InfrastructureManager/utils/persistent_dictionary.py/FileSystemBasedPersistentStore.get_all_entries