Exemplo n.º 1
0
class HashTag(models.NodeModel):
    tag = models.StringProperty()
    tweets = models.Relationship('TweetNode',
                                 rel_type='tagged_in',
                                 related_name="hashtags")
    users = models.Relationship('TwitterUser',
                                rel_type='tagged_for',
                                related_name="hashtags")
Exemplo n.º 2
0
class TweetNode(models.NodeModel):
    tweetID = models.StringProperty()
    in_reply_to_status_id = models.IntegerProperty()
    owner = models.Relationship('TwitterUser',
                                rel_type='tweeted_by',
                                related_name="tweets")
    objectID = models.StringProperty()
    createdAt = models.DateTimeProperty()
    replies = models.Relationship('self', rel_type='replied_as')
    retweets = models.Relationship('self', rel_type='retweeted_as')
Exemplo n.º 3
0
class TwitterUser(models.NodeModel):
    userID = models.StringProperty()
    userName = models.StringProperty()
    retweetCount = models.IntegerProperty()
    friendsCount = models.IntegerProperty()
    favouriteCount = models.IntegerProperty()
    followersCount = models.IntegerProperty()
    isGeoEnabled = models.BooleanProperty()
    language = models.StringProperty()
    #account = models.Relationship('Subscriber',rel_type='owns',related_name="twitterusers")
    follower = models.Relationship('self',
                                   rel_type='follows',
                                   related_name='followed_by')
Exemplo n.º 4
0
class Topic(models.NodeModel):
    topic = models.StringProperty()
    programmes = models.Relationship('Programme',
                                     rel_type='is_related_to',
                                     related_name="topics")
Exemplo n.º 5
0
class Node(models.NodeModel):
    name = models.StringProperty()

    Link = models.Relationship('self',rel_type='Link')#TODO: add link labels