Package Tribler :: Package Core :: Module RequestPolicy :: Class FriendsCoopDLOtherRQueryQuotumCrawlerAllowAllRequestPolicy

Class FriendsCoopDLOtherRQueryQuotumCrawlerAllowAllRequestPolicy

AbstractRequestPolicy --+    
                        |    
      CommonRequestPolicy --+
                            |
                           FriendsCoopDLOtherRQueryQuotumCrawlerAllowAllRequestPolicy

Allows friends to send all messages related to cooperative downloads, subjects all other peers to a remote query quotum of 100, and allows all peers to send all other non-crawler messages. Crawler messages are allowed from Crawlers only.
Instance Methods
 
allowed(self, permid, messageID)
Returns whether or not the peer identified by permid is allowed to send us a message of type messageID.

Inherited from CommonRequestPolicy: __init__, benign_random_peer, get_peer_nqueries, isCrawler, isFriend, isSuperPeer

Method Details

allowed(self, permid, messageID)

 
Returns whether or not the peer identified by permid is allowed to send us a message of type messageID.
Parameters:
  • permid - The permid of the sending peer.
  • messageID - A integer messageID, see Tribler.Core.BitTornado.BT1.MessageID
Returns:
Boolean.
Overrides: AbstractRequestPolicy.allowed