/*
 * 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.
 */
<'vlt'='http://www.day.com/jcr/vault/1.0'>
<'nt'='http://www.jcp.org/jcr/nt/1.0'>
<'mix'='http://www.jcp.org/jcr/mix/1.0'>
<'jcr'='http://www.jcp.org/jcr/1.0'>

// -----------------------------------------------------------------------------
// P A C K A G E S
// -----------------------------------------------------------------------------
// PACK_START
/**
 * Defines a file vault package. usually added to the jcr:content of a file node.
 * @node vlt:definition package definition
 */
[vlt:Package] mixin
  orderable
  + vlt:definition (nt:base) = vlt:PackageDefinition

/**
 * Package Definition
 * @prop version
 * @prop groupId package group id
 * @prop artifactId package artifact id
 * @prop lastUnpacked last unpack date
 * @prop lastUnpackedBy last unpack user
 * @prop dependencies maven style list of dependencies
 * @prop jcr:created creation date
 * @prop jcr:createdBy creation user
 * @prop jcr:description description of the package
 * @prop jcr:lastModified last modification date of the definition
 * @prop jcr:lastModifiedBy last modification user
 * @node filter list of package filters
 * @node extended optional extended data (thumbnails, detailed description, etc)
 */
[vlt:PackageDefinition] > nt:unstructured
  orderable
  - version (String)
  - groupId (String)
  - artifactId (String)
  - lastUnpacked (Date)
  - lastUnpackedBy (String)
  - dependencies (String) multiple
  - jcr:created (Date)
  - jcr:createdBy (String)
  - jcr:lastModified (Date)
  - jcr:lastModifiedBy (String)
  - jcr:description (String)
  + thumbnail (nt:base) = nt:unstructured
  + filter (nt:base) = nt:unstructured

/**
 * Node type to use as a marker for folders
 * e.g. decorate a nt:unstructured to prevent greedy aggregation
 */
[vlt:HierarchyNode] > nt:hierarchyNode mixin

/**
 * Marker node type that can be used to mark nodes for full coverage
 * aggregation
 */
[vlt:FullCoverage] mixin

 // PACK_END