LocalFS.js
X

Menu
N
core/lively/net/
...
../
callbacks/
tests/
tools/
CloudStorage.js
Dropbox.js
LocalFS.js
MediaStreaming.js (not parsed)
OneDrive.js (not parsed)
SessionTracker.js
WebSockets.js (not parsed)
Wiki.js (not parsed)
thisModule (extension)
-----
-----
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
module('lively.net.LocalFS').requires().toRun(function(thisModule) {
Object.extend(thisModule, {    
    _request: function(func) {
        var answer = {
            status: {
                isSuccess: Functions.False, isDone: Functions.False, isForbidden: Functions.False,
                code: function() { return answer.statusCode }
            },
            content: null,
            contentDocument: null,
            subCollections: null,
            subDocuments: null
        }
        window.navigator.webkitPersistentStorage.requestQuota(1024*1024, function() {
            window.webkitRequestFileSystem(window.PERSISTENT , 1024*1024, function (ls) {
                func(ls, answer);
            });
        });
        return answer;
    },
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
>
<
CloudStorageWebRequests.js
X

Menu
N
core/lively/experimental/
...
CloudStorageSynchronization.js (not parsed)
CloudStorageWebRequests.js
CopyAndPaste.js (not parsed)
DebugEvents.js (not parsed)
ExperimentalFeatures.js (not parsed)
FixWindowsCopyBug.js (not parsed)
LoadOldPages.js (not parsed)
MethodFinder.js (not parsed)
PartsMenu.js (not parsed)
RobustLoading.js (not parsed)
SimpleBoundEval.js (not parsed)
TextPaste.js (not parsed)
Todo.js (not parsed)
CloudStorageWebRequestCloudDriveLayer
CloudStorageWebRequestsLayer
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
module('lively.experimental.CloudStorageWebRequests').requires('cop.Layers', 'lively.Network', 'lively.ide
.SourceDatabase', 'lively.net.OneDrive', 'lively.net.Dropbox', 'lively.net.LocalFS').toRun(function() {
cop.create("CloudStorageWebRequestsLayer").refineClass(URL, {
    get splitter() {
        return new RegExp('^(http|https|file|dropbox|onedrive|localfs)://([^/:]*)(:([0-9]+))?(/.*)?$');
    }
}).refineObject(URL, {
    ensureAbsoluteRootPathURL: function (urlString) {
        return /^(http|file|dropbox|onedrive|localfs).*/.test(urlString) ?
            new URL(urlString) :
            new URL(Config.rootPath).withRelativePath(urlString);
    },
    ensureAbsoluteCodeBaseURL: function(urlString) {
        return /^(http|file|dropbox|onedrive|localfs).*/.test(urlString) ?
            new URL(urlString) :
            URL.codeBase.withRelativePath(urlString);
    },
    ensureAbsoluteURL: function(urlString) {
        return /^(http|file|dropbox|onedrive|localfs).*/.test(urlString) ?
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
>
<
X
Saving lively.experimental.CloudStorageWebRequests... Successfully saved Successfully evaluated lively.experimental.CloudStorageWebRequests
depth: 1
reset
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
show vars
JavaScript Workspace
X

Menu