Code Monkey home page Code Monkey logo

Comments (7)

abada avatar abada commented on June 21, 2024

iam using phonegap -v
3.3.0-0.18.0

from cordova-plugin-zip.

agrieve avatar agrieve commented on June 21, 2024

I think likely you need to update your version of org.apache.cordova.file

from cordova-plugin-zip.

abada avatar abada commented on June 21, 2024

how update version of org.apache.cordova.file ?? do you mean update phonegap version ?

from cordova-plugin-zip.

agrieve avatar agrieve commented on June 21, 2024

A bit crazy that we don't have a better way for it yet, but for now, you
can see what version you have by looking at the bottom of:

platforms/ios/www/cordova_plugins.js

On Wed, Mar 26, 2014 at 11:59 AM, Abdel latif Ahmed Henno <
[email protected]> wrote:

how update version of org.apache.cordova.file ?? do you mean update
phonegap version ?


Reply to this email directly or view it on GitHubhttps://github.com//issues/22#issuecomment-38725219
.

from cordova-plugin-zip.

abada avatar abada commented on June 21, 2024

i updated phonegap & cordova 3.4.0

here is bottom of platforms/ios/www/cordova_plugins.js

{
"file": "plugins/org.chromium.zip/zip.js",
"id": "org.chromium.zip.Zip",
"clobbers": [
"zip"
]
}

but there is the same errors !

from cordova-plugin-zip.

abada avatar abada commented on June 21, 2024

this is CDVFile.h file

/*
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
*/

#import <Foundation/Foundation.h>
#import <Cordova/CDVPlugin.h>

enum CDVFileError {
NO_ERROR = 0,
NOT_FOUND_ERR = 1,
SECURITY_ERR = 2,
ABORT_ERR = 3,
NOT_READABLE_ERR = 4,
ENCODING_ERR = 5,
NO_MODIFICATION_ALLOWED_ERR = 6,
INVALID_STATE_ERR = 7,
SYNTAX_ERR = 8,
INVALID_MODIFICATION_ERR = 9,
QUOTA_EXCEEDED_ERR = 10,
TYPE_MISMATCH_ERR = 11,
PATH_EXISTS_ERR = 12
};
typedef int CDVFileError;

enum CDVFileSystemType {
TEMPORARY = 0,
PERSISTENT = 1
};
typedef int CDVFileSystemType;

extern NSString* const kCDVAssetsLibraryPrefix;

@interface CDVFile : CDVPlugin {
NSString* appDocsPath;
NSString* appLibraryPath;
NSString* appTempPath;
NSString* persistentPath;
NSString* temporaryPath;

BOOL userHasAllowed;

}

  • (NSNumber_)checkFreeDiskSpace:(NSString_)appPath;
  • (NSString_)getAppPath:(NSString_)pathFragment;
    // -(NSString_) getFullPath: (NSString_)pathFragment;
  • (void)requestFileSystem:(CDVInvokedUrlCommand*)command;
  • (NSDictionary_)getDirectoryEntry:(NSString_)fullPath isDirectory:(BOOL)isDir;
  • (void)resolveLocalFileSystemURI:(CDVInvokedUrlCommand*)command;
  • (void)getDirectory:(CDVInvokedUrlCommand*)command;
  • (void)getFile:(CDVInvokedUrlCommand*)command;
  • (void)getParent:(CDVInvokedUrlCommand*)command;
  • (void)getMetadata:(CDVInvokedUrlCommand*)command;
  • (void)removeRecursively:(CDVInvokedUrlCommand*)command;
  • (void)remove:(CDVInvokedUrlCommand*)command;
  • (CDVPluginResult_)doRemove:(NSString_)fullPath;
  • (void)copyTo:(CDVInvokedUrlCommand*)command;
  • (void)moveTo:(CDVInvokedUrlCommand*)command;
  • (BOOL)canCopyMoveSrc:(NSString_)src ToDestination:(NSString_)dest;
  • (void)doCopyMove:(CDVInvokedUrlCommand_)command isCopy:(BOOL)bCopy;
    // - (void) toURI:(CDVInvokedUrlCommand_)command;
  • (void)getFileMetadata:(CDVInvokedUrlCommand*)command;
  • (void)readEntries:(CDVInvokedUrlCommand*)command;
  • (void)readAsText:(CDVInvokedUrlCommand*)command;
  • (void)readAsDataURL:(CDVInvokedUrlCommand*)command;
  • (void)readAsArrayBuffer:(CDVInvokedUrlCommand*)command;
  • (NSString_)getMimeTypeFromPath:(NSString_)fullPath;
  • (void)write:(CDVInvokedUrlCommand*)command;
  • (void)testFileExists:(CDVInvokedUrlCommand*)command;
  • (void)testDirectoryExists:(CDVInvokedUrlCommand_)command;
    // - (void) createDirectory:(CDVInvokedUrlCommand_)command;
    // - (void) deleteDirectory:(CDVInvokedUrlCommand_)command;
    // - (void) deleteFile:(CDVInvokedUrlCommand_)command;
  • (void)getFreeDiskSpace:(CDVInvokedUrlCommand*)command;
  • (void)truncate:(CDVInvokedUrlCommand*)command;

// - (BOOL) fileExists:(NSString_)fileName;
// - (BOOL) directoryExists:(NSString_)dirName;

  • (void)writeToFile:(NSString_)fileName withData:(NSData_)data append:(BOOL)shouldAppend callback:(NSString*)callbackId;
  • (void)writeToFile:(NSString_)fileName withString:(NSString_)data encoding:(NSStringEncoding)encoding append:(BOOL)shouldAppend callback:(NSString*)callbackId;
  • (unsigned long long)truncateFile:(NSString*)filePath atPosition:(unsigned long long)pos;

@Property (nonatomic, strong) NSString* appDocsPath;
@Property (nonatomic, strong) NSString* appLibraryPath;
@Property (nonatomic, strong) NSString* appTempPath;
@Property (nonatomic, strong) NSString* persistentPath;
@Property (nonatomic, strong) NSString* temporaryPath;
@Property BOOL userHasAllowed;

@EnD

#define kW3FileTemporary @"temporary"
#define kW3FilePersistent @"persistent"

is not same as
https://github.com/apache/cordova-plugin-file/blob/master/src/ios/CDVFile.h

??

from cordova-plugin-zip.

agrieve avatar agrieve commented on June 21, 2024

The bottom of that file should look like:

module.exports.metadata =
// TOP OF METADATA
{
"org.apache.cordova.file": "1.0.2-dev",
"org.apache.cordova.inappbrowser": "0.3.3",
"org.apache.cordova.network-information": "0.2.7",
"org.apache.cordova.keyboard": "0.1.2",
"org.apache.cordova.statusbar": "0.1.4",
"org.chromium.navigation": "1.0.1",
"org.chromium.bootstrap": "1.0.1",
"org.chromium.i18n": "1.0.1",
"org.chromium.polyfill.CustomEvent": "1.0.0",
"org.chromium.polyfill.xhr_features": "1.0.0",
"org.chromium.polyfill.blob_constructor": "1.0.0",
"org.chromium.common": "1.0.1",
"org.chromium.storage": "1.0.1",
"org.chromium.runtime": "1.0.1"
}
// BOTTOM OF METADATA

Maybe try using cordova-cli instead of phonegap-cli?

Another way to find the version is to look in:
plugins/org.apache.cordova.file/plugin.xml

The latest version of file is 1.0.1

On Wed, Mar 26, 2014 at 2:50 PM, Abdel latif Ahmed Henno <
[email protected]> wrote:

this is CDVFile.h file

/*
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
*/

#import
#import

enum CDVFileError {
NO_ERROR = 0,
NOT_FOUND_ERR = 1,
SECURITY_ERR = 2,
ABORT_ERR = 3,
NOT_READABLE_ERR = 4,
ENCODING_ERR = 5,
NO_MODIFICATION_ALLOWED_ERR = 6,
INVALID_STATE_ERR = 7,
SYNTAX_ERR = 8,
INVALID_MODIFICATION_ERR = 9,
QUOTA_EXCEEDED_ERR = 10,
TYPE_MISMATCH_ERR = 11,
PATH_EXISTS_ERR = 12
};
typedef int CDVFileError;

enum CDVFileSystemType {
TEMPORARY = 0,
PERSISTENT = 1
};
typedef int CDVFileSystemType;

extern NSString* const kCDVAssetsLibraryPrefix;

@interface https://github.com/interface CDVFile : CDVPlugin {
NSString* appDocsPath;
NSString* appLibraryPath;
NSString* appTempPath;
NSString* persistentPath;
NSString* temporaryPath;

BOOL userHasAllowed;

}

  • (NSNumber_)checkFreeDiskSpace:(NSString_)appPath;

  • (NSString_)getAppPath:(NSString_)pathFragment; // -(NSString_)
    getFullPath: (NSString_)pathFragment;

  • (void)requestFileSystem:(CDVInvokedUrlCommand*)command;

  • (NSDictionary_)getDirectoryEntry:(NSString_)fullPath
    isDirectory:(BOOL)isDir;

  • (void)resolveLocalFileSystemURI:(CDVInvokedUrlCommand*)command;

  • (void)getDirectory:(CDVInvokedUrlCommand*)command;

  • (void)getFile:(CDVInvokedUrlCommand*)command;

  • (void)getParent:(CDVInvokedUrlCommand*)command;

  • (void)getMetadata:(CDVInvokedUrlCommand*)command;

  • (void)removeRecursively:(CDVInvokedUrlCommand*)command;

  • (void)remove:(CDVInvokedUrlCommand*)command;

  • (CDVPluginResult_)doRemove:(NSString_)fullPath;

  • (void)copyTo:(CDVInvokedUrlCommand*)command;

  • (void)moveTo:(CDVInvokedUrlCommand*)command;

  • (BOOL)canCopyMoveSrc:(NSString_)src ToDestination:(NSString_)dest;

  • (void)doCopyMove:(CDVInvokedUrlCommand_)command isCopy:(BOOL)bCopy;
    // - (void) toURI:(CDVInvokedUrlCommand_)command;

  • (void)getFileMetadata:(CDVInvokedUrlCommand*)command;

    (void)readEntries:(CDVInvokedUrlCommand*)command;

    (void)readAsText:(CDVInvokedUrlCommand*)command;

  • (void)readAsDataURL:(CDVInvokedUrlCommand*)command;

  • (void)readAsArrayBuffer:(CDVInvokedUrlCommand*)command;

  • (NSString_)getMimeTypeFromPath:(NSString_)fullPath;

  • (void)write:(CDVInvokedUrlCommand*)command;

  • (void)testFileExists:(CDVInvokedUrlCommand*)command;

  • (void)testDirectoryExists:(CDVInvokedUrlCommand_)command; // -
    (void) createDirectory:(CDVInvokedUrlCommand_)command; // - (void)
    deleteDirectory:(CDVInvokedUrlCommand_)command; // - (void)
    deleteFile:(CDVInvokedUrlCommand_)command;

  • (void)getFreeDiskSpace:(CDVInvokedUrlCommand*)command;

  • (void)truncate:(CDVInvokedUrlCommand*)command;

// - (BOOL) fileExists:(NSString_)fileName;
// - (BOOL) directoryExists:(NSString_)dirName;

  • (void)writeToFile:(NSString_)fileName withData:(NSData_)data
    append:(BOOL)shouldAppend callback:(NSString*)callbackId;
  • (void)writeToFile:(NSString_)fileName withString:(NSString_)data
    encoding:(NSStringEncoding)encoding append:(BOOL)shouldAppend
    callback:(NSString*)callbackId;
  • (unsigned long long)truncateFile:(NSString*)filePath
    atPosition:(unsigned long long)pos;

@Property https://github.com/property (nonatomic, strong) NSString*
appDocsPath;
@Property https://github.com/property (nonatomic, strong) NSString*
appLibraryPath;
@Property https://github.com/property (nonatomic, strong) NSString*
appTempPath;
@Property https://github.com/property (nonatomic, strong) NSString*
persistentPath;
@Property https://github.com/property (nonatomic, strong) NSString*
temporaryPath;
@Property https://github.com/property BOOL userHasAllowed;

@EnD https://github.com/end

#define kW3FileTemporary @"temporary"
#define kW3FilePersistent @"persistent"

is not same as
https://github.com/apache/cordova-plugin-file/blob/master/src/ios/CDVFile.h

??


Reply to this email directly or view it on GitHubhttps://github.com//issues/22#issuecomment-38744680
.

from cordova-plugin-zip.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.