Created
September 18, 2013 03:34
-
-
Save rynomad/6604213 to your computer and use it in GitHub Desktop.
NDN CSTable hack
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function getEntryForRegisteredPrefix(name) { | |
for (var i = 0; i < NDN.CSTable.length; i++) { | |
console.log(NDN.CSTable[i], name); | |
var entry = new Name(NDN.CSTable[i].name); | |
var interestName = new Interest(entry); | |
if (interestName.matches_name(new Name(name)) == true){ | |
console.log('Match!!!', NDN.CSTable[i], name); | |
return NDN.CSTable[i]; | |
} | |
} | |
return null; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment