summaryrefslogtreecommitdiff
path: root/src/Data/Kademlia/Routing/Table.hs
diff options
context:
space:
mode:
Diffstat (limited to 'src/Data/Kademlia/Routing/Table.hs')
-rw-r--r--src/Data/Kademlia/Routing/Table.hs50
1 files changed, 0 insertions, 50 deletions
diff --git a/src/Data/Kademlia/Routing/Table.hs b/src/Data/Kademlia/Routing/Table.hs
deleted file mode 100644
index 056692f3..00000000
--- a/src/Data/Kademlia/Routing/Table.hs
+++ /dev/null
@@ -1,50 +0,0 @@
1-- |
2-- Copyright : (c) Sam T. 2013
3-- License : MIT
4-- Maintainer : pxqr.sta@gmail.com
5-- Stability : experimental
6-- Portability : portable
7--
8-- Routing table used to lookup . Internally it uses not balanced tree
9--
10-- TODO write module synopsis
11module Data.Kademlia.Routing.Table
12 ( -- ContactInfo
13-- , Table
14 ) where
15
16import Control.Applicative
17import Data.ByteString
18import Data.List as L
19import Data.Maybe
20
21import Network.BitTorrent.Peer
22
23{-
24type NodeID = ByteString
25type InfoHash = ByteString
26
27data ContactInfo = ContactInfo {
28 peerAddr :: PeerAddr
29 , nodeID :: NodeID
30 } deriving (Show, Eq)
31
32
33type Distance = NodeID
34
35-- |
36data Table = Table {
37 routeTree :: Tree
38 , maxBucketSize :: Int
39 }
40
41insert :: NodeID -> Table -> Table
42insert x t = undefined
43
44closest :: InfoHash -> Table -> [NodeID]
45closest = undefined
46
47
48-- TODO table serialization: usually we need to save table between
49-- target program executions for bootstrapping
50-} \ No newline at end of file