rpm_open

(PECL rpmreader >= 0.1.0)

rpm_openOpens an RPM file

说明

resource rpm_open ( string $filename )

rpm_open() will open an RPM file and will determine if the file is a valid RPM file.

参数

filename

The filename of the RPM file you wish to open.

返回值

If the open succeeds, then rpm_open() will return a file pointer resource to the newly opened file. On error, the function will return FALSE.

范例

Example #1 rpm_open() example

<?php

$file 
"/path/to/file.rpm";
$rpmr rpm_open($file);

rpm_close($rpmr);

?>

参见

User Contributed Notes

matt dot koola at gmail dot com 03-Jul-2013 02:46
It's worth noting that a URL to an RPM package can be passed to  rpm_open().
tpe at dansupport dot dk 08-Aug-2006 11:40
Just to list all tags as of version 0.3 beta:

RPMREADER_NAME
RPMREADER_MINIMUM
RPMREADER_VERSION
RPMREADER_RELEASE
RPMREADER_EPOCH
RPMREADER_SERIAL
RPMREADER_SUMMARY
RPMREADER_DESCRIPTION
RPMREADER_BUILDTIME
RPMREADER_BUILDHOST
RPMREADER_INSTALLTIME
RPMREADER_SIZE
RPMREADER_DISTRIBUTION
RPMREADER_VENDOR
RPMREADER_GIF
RPMREADER_XPM
RPMREADER_LICENSE
RPMREADER_COPYRIGHT
RPMREADER_PACKAGER
RPMREADER_GROUP
RPMREADER_SOURCE
RPMREADER_PATCH
RPMREADER_URL
RPMREADER_OS
RPMREADER_ARCH
RPMREADER_PREIN
RPMREADER_POSTIN
RPMREADER_PREUN
RPMREADER_POSTUN
RPMREADER_OLDFILENAMES
RPMREADER_FILESIZES
RPMREADER_FILESTATES
RPMREADER_FILEMODES
RPMREADER_FILERDEVS
RPMREADER_FILEMTIMES
RPMREADER_FILEMD5S
RPMREADER_FILELINKTOS
RPMREADER_FILEFLAGS
RPMREADER_FILEUSERNAME
RPMREADER_FILEGROUPNAME
RPMREADER_ICON
RPMREADER_SOURCERPM
RPMREADER_FILEVERIFYFLAGS
RPMREADER_ARCHIVESIZE
RPMREADER_PROVIDENAME
RPMREADER_PROVIDES
RPMREADER_REQUIREFLAGS
RPMREADER_REQUIRENAME
RPMREADER_REQUIREVERSION
RPMREADER_CONFLICTFLAGS
RPMREADER_CONFLICTNAME
RPMREADER_CONFLICTVERSION
RPMREADER_EXCLUDEARCH
RPMREADER_EXCLUDEOS
RPMREADER_EXCLUSIVEARCH
RPMREADER_EXCLUSIVEOS
RPMREADER_RPMVERSION
RPMREADER_TRIGGERSCRIPTS
RPMREADER_TRIGGERNAME
RPMREADER_TRIGGERVERSION
RPMREADER_TRIGGERFLAGS
RPMREADER_TRIGGERINDEX
RPMREADER_VERIFYSCRIPT
RPMREADER_CHANGELOGTIME
RPMREADER_CHANGELOGNAME
RPMREADER_CHANGELOGTEXT
RPMREADER_PREINPROG
RPMREADER_POSTINPROG
RPMREADER_PREUNPROG
RPMREADER_POSTUNPROG
RPMREADER_BUILDARCHS
RPMREADER_OBSOLETENAME
RPMREADER_OBSOLETES
RPMREADER_VERIFYSCRIPTPROG
RPMREADER_TRIGGERSCRIPTPROG
RPMREADER_COOKIE
RPMREADER_FILEDEVICES
RPMREADER_FILEINODES
RPMREADER_FILELANGS
RPMREADER_PREFIXES
RPMREADER_INSTPREFIXES
RPMREADER_PROVIDEFLAGS
RPMREADER_PROVIDEVERSION
RPMREADER_OBSOLETEFLAGS
RPMREADER_OBSOLETEVERSION
RPMREADER_DIRINDEXES
RPMREADER_BASENAMES
RPMREADER_DIRNAMES
RPMREADER_OPTFLAGS
RPMREADER_DISTURL
RPMREADER_PAYLOADFORMAT
RPMREADER_PAYLOADCOMPRESSOR
RPMREADER_PAYLOADFLAGS
RPMREADER_INSTALLCOLOR
RPMREADER_INSTALLTID
RPMREADER_REMOVETID
RPMREADER_RHNPLATFORM
RPMREADER_PLATFORM
RPMREADER_PATCHESNAME
RPMREADER_PATCHESFLAGS
RPMREADER_PATCHESVERSION
RPMREADER_CACHECTIME
RPMREADER_CACHEPKGPATH
RPMREADER_CACHEPKGSIZE
RPMREADER_CACHEPKGMTIME
RPMREADER_FILECOLORS
RPMREADER_FILECLASS
RPMREADER_CLASSDICT
RPMREADER_FILEDEPENDSX
RPMREADER_FILEDEPENDSN
RPMREADER_DEPENDSDICT
RPMREADER_SOURCEPKGID
RPMREADER_FILECONTEXTS
RPMREADER_FSCONTEXTS
RPMREADER_RECONTEXTS
RPMREADER_POLICIES
RPMREADER_MAXIMUM
RPMreader version