Univeristy of Alabama in Huntsville

UAH LTG IDL Library

IDL Routines from Phillip Bitzer and UAH Lightning Group

summary     class     fields     routine details     file attributes

misc/file/

pmb_is_gz.pro

Files


This routine will attempt to determine if a file is "gzipped" or not by peeking at the file extension. On error, -1 is returned.

Examples

is_gz = pmb_is_gz(filename)

Author information

Author

Phillip M. Bitzer, University of Alabama in Huntsville, pm.bitzer "AT" uah.edu

History

Modification History:

First written: Sometime in 2012 Added error catcher and cleaned documentation

Routines

top pmb_is_gz

result = pmb_is_gz(filename)

Find out if a file is gzipped or not

Return value

A byte value with:

1B: it's gzipped 0B: it's not -1B: an error occurred

Parameters

filename in required type=strine

The file to probe

Other attributes

Uses:

None

File attributes

Modification date: Tue Apr 4 15:07:29 2017
Lines: 24
Docformat: rst rst