📄 jar.h
字号:
/*0001*//*
/*0002./ * Copyright (c) 2000-2001 Sun Microsystems, Inc. All Rights Reserved.
/*0003./ *
/*0004./ * This software is the confidential and proprietary information of Sun
/*0005./ * Microsystems, Inc. ("Confidential Information"). You shall not
/*0006./ * disclose such Confidential Information and shall use it only in
/*0007./ * accordance with the terms of the license agreement you entered into
/*0008./ * with Sun.
/*0009./ *
/*0010./ * SUN MAKES NO REPRESENTATIONS OR WARRANTIES ABOUT THE SUITABILITY OF THE
/*0011./ * SOFTWARE, EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
/*0012./ * IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
/*0013./ * PURPOSE, OR NON-INFRINGEMENT. SUN SHALL NOT BE LIABLE FOR ANY DAMAGES
/*0014./ * SUFFERED BY LICENSEE AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
/*0015./ * THIS SOFTWARE OR ITS DERIVATIVES.
/*0016./ *
/*0017./ */
/*0018*/
/*0019*//*=========================================================================
/*0020./ * SYSTEM: KVM
/*0021./ * SUBSYSTEM: JAR file reader.
/*0022./ * FILE: jar.h
/*0023./ * OVERVIEW: Declarations for reading JAR files and their entries.
/*0024./ * AUTHOR: Ioi Lam, Tasneem Sayeed, Frank Yellin
/*0025./ *=======================================================================*/
/*0026*/
/*0027*/#ifndef JAR_FILES_USE_STDIO
/*0028*/#define JAR_FILES_USE_STDIO 1
/*0029*/#endif
/*0030*/
/*0031*/typedef struct jarInfoStruct {
/*0032*/ union {
/*0033*/ struct {
/*0034*/ void /* FILE */ *file; /* We may not have stdio loaded */
/*0035*/ unsigned long locOffset; /* Offset of local directory */
/*0036*/ unsigned long cenOffset; /* Offset of central directory */
/*0037*/ } jar;
/*0038*/ struct {
/*0039*/ const unsigned char *base;
/*0040*/ const unsigned char *locPtr;
/*0041*/ const unsigned char *cenPtr;
/*0042*/ } mjar;
/*0043*/ } u;
/*0044*/} *JAR_INFO, **JAR_INFO_HANDLE;
/*0045*/
/*0046*/bool_t openJARFile(void *nameOrAddress, int length, JAR_INFO entry);
/*0047*/
/*0048*/void closeJARFile(JAR_INFO entry);
/*0049*/
/*0050*/void *
/*0051*/loadJARFileEntry(JAR_INFO, const char *filename, long *length,
/*0052*/ int extraBytes);
/*0053*/
/*0054*/
/*0055*/typedef bool_t (*JARFileTestFunction)(const char *name, int nameLength,
/*0056*/ int *extraBytes, void *info);
/*0057*/typedef void (*JARFileRunFunction)(const char *name, int nameLength,
/*0058*/ void *value, long length, void *info);
/*0059*/
/*0060*/void
/*0061*/loadJARFileEntries(JAR_INFO entry,
/*0062*/ JARFileTestFunction, JARFileRunFunction, void*);
/*0063*/
/*0064*/
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -