<?xml version="1.0"?>
<!--
 * geophysicalResourceFileCollection.xsl - You may not remove or change this notice. Do not sell
 * this as your own work or remove this copyright notice.
 * 
 * Credit given (and copyright statements maintained) where code used directly
 * or modified from other sources.
 * 
 * This software is Copyright 2006 The Regents of the University of
 * California. All Rights Reserved.
 * 
 * Permission to use, copy, modify, and distribute this software and its
 * documentation for educational, research and non-profit purposes, without fee,
 * and without a written agreement is hereby granted, provided that the above
 * copyright notice, this paragraph and the following three paragraphs appear in
 * all copies.
 * 
 * Permission to incorporate this software into commercial products may be
 * obtained by contacting Technology Transfer Office 9500 Gilman Drive, Mail
 * Code 0910 University of California La Jolla, CA 92093-0910 (858) 534-5815
 * invent@ucsd.edu
 * 
 * This software program and documentation are copyrighted by The Regents of the
 * University of California. The software program and documentation are supplied
 * "as is", without any accompanying services from The Regents. The Regents does
 * not warrant that the operation of the program will be uninterrupted or
 * error-free. The end-user understands that the program was developed for
 * research purposes and is advised not to rely exclusively on the program for
 * any reason.
 * 
 * IN NO EVENT SHALL THE UNIVERSITY OF CALIFORNIA BE LIABLE TO ANY PARTY FOR
 * DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, INCLUDING
 * LOST PROFITS, ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION,
 * EVEN IF THE UNIVERSITY OF CALIFORNIA HAS BEEN ADVISED OF THE POSSIBILITY OF
 * SUCH DAMAGE. THE UNIVERSITY OF CALIFORNIA SPECIFICALLY DISCLAIMS ANY
 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED
 * HEREUNDER IS ON AN "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO
 * OBLIGATIONS TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR
 * MODIFICATIONS.
 *  
 -->
<!-- cvs:$Id: geophysicalResourceFileCollection.xsl,v 1.8 2006/07/21 17:29:20 pjamason Exp $ -->
<!--
 * xsl stylesheet used to convert a geophysicalResourceFileCollection xml instance 
 * into tab-delimited plain text 
 * 
 * 
 * Author: Paul Jamason, SOPAC/IGPP/SIO/UCSD; Date: 07/2006
 -->
 <!-- do we need schmea location for grws instead of ns? -->
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
    xmlns:grws="http://sopac.ucsd.edu/grws"
    xmlns:gen="http://sopac.ucsd.edu/general" xmlns:dc="http://purl.org/dc/elements/1.1/">
    <xsl:variable name="tab"><xsl:text>&#x09;</xsl:text></xsl:variable>
    <xsl:output method="text" encoding="UTF-8"/>
    <xsl:template match="grws:geophysicalResourceFileCollection">
        <xsl:for-each select="grws:geophysicalResourceFile">
            <xsl:sort select="dc:identifier"/>
            <xsl:value-of select="dc:identifier"/>
            <xsl:value-of select="$tab"/>
            <xsl:value-of select="dc:type"/>
            <xsl:value-of select="$tab"/>
            <xsl:value-of select="dc:format"/>
            <xsl:value-of select="$tab"/>
            <xsl:value-of select="dc:date"/>
            <xsl:value-of select="$tab"/>            
            <xsl:value-of select="grws:size/gen:fileSize"/>
            <xsl:text>&#10;</xsl:text>
        </xsl:for-each>
    </xsl:template>
</xsl:stylesheet>
