Пример #1
0
 public AnnotationsFetcher(FaceProcessor faceProcessor, string servicePrefix, string instance)
 {
     faceProcessor_   = faceProcessor;
     serviceInstance_ = instance;
     serviceNamespace = new Namespace(new Name(servicePrefix));
     serviceNamespace.setFace(faceProcessor.getFace());
 }
Пример #2
0
    public void fetch(string assetNdnUri, AssetFetcherHandler onAssetFetched)
    {
        Debug.Log("Will fetch asset " + assetNdnUri);

        var prefix = new Namespace(assetNdnUri);

        prefix.setFace(faceProcessor_.getFace());

        var ndnfsFile = new NdnfsFile(prefix, delegate(NdnfsFile nf, Namespace contentNamespace, Blob content) {
            Debug.Log("Got asset contents; size " + content.size());

            onAssetFetched(AssetBundle.LoadFromMemory(content.getImmutableArray()));
        });

        ndnfsFile.start();
    }