Beispiel #1
0
 def getUser(self,
             instance,
             userId,
             twitterSession,
             recursive=True,
             projection=None):
     return readUserFromCache(userId, twitterSession, instance, recursive,
                              projection)
Beispiel #2
0
    def isDeepUserObjectIn(self, sourceUser):
        assert isinstance(sourceUser, User)

        cachedUser = readUserFromCache(sourceUser.id, sourceUser.twitter_session, sourceUser.instance_key, False, UserProjection.FollowerEnrichmentFlags())
        if cachedUser is None:
            return False

        assert isinstance(cachedUser, User)
        return cachedUser.is_followers_loaded or cachedUser.queued_for_follower_enrichment
Beispiel #3
0
    def isDeepUserObjectIn(self, sourceUser):
        assert isinstance(sourceUser, User)

        cachedUser = readUserFromCache(
            sourceUser.id, sourceUser.twitter_session, sourceUser.instance_key,
            False, UserProjection.FollowerEnrichmentFlags())
        if cachedUser is None:
            return False

        assert isinstance(cachedUser, User)
        return cachedUser.is_followers_loaded or cachedUser.queued_for_follower_enrichment
Beispiel #4
0
 def getUser(self, instance, userId, twitterSession, recursive=True, projection=None):
     return readUserFromCache(userId, twitterSession, instance, recursive, projection)