コード例 #1
0
        // Insert the new node in the SavedForOffline table.
        public static void Insert(MNode megaNode, bool isSelectedForOffline = false)
        {
            var nodeOfflineLocalPath = Path.Combine(ApplicationData.Current.LocalFolder.Path, AppResources.DownloadsDirectory,
                                                    SdkService.MegaSdk.getNodePath(megaNode).Remove(0, 1).Replace("/", "\\"));

            var sfoNode = new SavedForOffline()
            {
                Fingerprint          = SdkService.MegaSdk.getNodeFingerprint(megaNode),
                Base64Handle         = megaNode.getBase64Handle(),
                LocalPath            = nodeOfflineLocalPath,
                ParentBase64Handle   = (SdkService.MegaSdk.getParentNode(megaNode)).getBase64Handle(),
                IsSelectedForOffline = isSelectedForOffline
            };

            Insert(sfoNode);
        }
コード例 #2
0
 // Delete specific node
 public static void DeleteNode(SavedForOffline node)
 {
     DataBaseHelper <SavedForOffline> .DeleteNode(node);
 }
コード例 #3
0
 // Insert the new node in the database.
 public static void Insert(SavedForOffline newNode)
 {
     DataBaseHelper <SavedForOffline> .Insert(newNode);
 }
コード例 #4
0
 // Update existing node
 public static void UpdateNode(SavedForOffline node)
 {
     DataBaseHelper <SavedForOffline> .UpdateNode(node);
 }