001    /*
002     * file CcStorageLocation.java
003     * 
004     * Licensed Materials - Property of IBM
005     * Restricted Materials of IBM 
006     *
007     * com.ibm.rational.wvcm.stp.cc.CcStorageLocation
008     *
009     * (C) Copyright IBM Corporation 2010, 2011.  All Rights Reserved.
010     * Note to U.S. Government Users Restricted Rights:  Use, duplication or 
011     * disclosure restricted by GSA ADP  Schedule Contract with IBM Corp.
012     */
013    
014    package com.ibm.rational.wvcm.stp.cc;
015    
016    import static com.ibm.rational.wvcm.stpex.StpExBase.PROPERTY_NAMESPACE;
017    
018    import javax.wvcm.WvcmException;
019    import javax.wvcm.PropertyNameList.PropertyName;
020    
021    /**
022     * <p>
023     * A proxy for a ClearCase storage location.
024     * A storage location provides a simplified way for users to specify the
025     * storage directory for ClearCase VOBs and views without resorting to explicit 
026     * pathnames.
027     * </p>
028     */
029    
030    public interface CcStorageLocation extends CcResource {
031    
032        /**
033         * Name of the server hosting the storage location
034         */
035        PropertyName<String> SERVER_HOST =
036            new PropertyName<String>(PROPERTY_NAMESPACE, "stgloc-server-host");
037    
038        /**
039         * Get the value of this proxy's {@link #SERVER_HOST} property.
040         * @return this storage location's server host
041         * @throws WvcmException if this proxy doesn't define a value for this property.
042         */
043        String getServerHost() throws WvcmException;
044    
045        /**
046         * Type of the storage location
047         */
048        enum StorageType {
049            /** This is a view storage location. */
050            VIEW,
051    
052            /** This is a VOB storage location. */
053            VOB;
054        }
055    
056        /**
057         * The type of storage location
058         */
059        PropertyName<StorageType> STORAGE_TYPE =
060            new PropertyName<StorageType>(PROPERTY_NAMESPACE, "stgloc-storage-type");
061    
062        /**
063         * Get the value of this proxy's {@link #STORAGE_TYPE} property.
064         * @return this storage location's type
065         * @throws WvcmException if this proxy doesn't define a value for this property.
066         */
067        StorageType getStorageType() throws WvcmException;
068     
069    }