com.sapportals.wcm.repository

Interface IVersionResource


public interface IVersionResource

Interface for version (revision) resources (see RFC3253 ).

Copyright (c) SAP AG 2002-2004


Field Summary
static IName FORKBEHAVIOUR_DISCOURAGED
          Forks are discouraged, and a checkin/checkout request must specifically allow them.
static IName FORKBEHAVIOUR_FORBIDDEN
          Forks are forbidden, and a checkin/checkout requests creating a fork will be rejected.
 
Method Summary
 void addLabel(String labelName)
          Adds the given label if and only if it didn't exist before in the version's version history.
 ICheckOutInfo2 checkOut(boolean forkOk)
          Checkout the version.
 IResourceList getCheckedOutResources()
           
 IRidSet getCheckedOutRIDs()
           
 Set getCheckInForkBehaviour()
           
 Set getCheckOutForkBehaviour()
           
 Set getLabelSet()
           
 IResourceList getPredecessorResources()
           
 IRidSet getPredecessorRIDs()
           
 IResourceList getSuccessorResources()
           
 IRidSet getSuccessorRIDs()
           
 IResource getVersionHistoryResource()
           
 RID getVersionHistoryRID()
           
 void removeLabel(String labelName)
          Removes the given label from the resource if present (removing non-existing labels should be signaled through an exception)
 void setLabel(String labelName)
          Sets the given label on the version (removing it from other versions if present)
 

Field Detail

FORKBEHAVIOUR_DISCOURAGED

public static final IName FORKBEHAVIOUR_DISCOURAGED
Forks are discouraged, and a checkin/checkout request must specifically allow them.


FORKBEHAVIOUR_FORBIDDEN

public static final IName FORKBEHAVIOUR_FORBIDDEN
Forks are forbidden, and a checkin/checkout requests creating a fork will be rejected.

Method Detail

checkOut

public ICheckOutInfo2 checkOut(boolean forkOk)
                        throws ResourceException
Checkout the version.

Parameters:
forkOk - set to true if it's ok to cause a fork in the version history (may be rejected nevertheless if the checkout fork behaviour dictates this).
Returns:
information about chechkout result
Throws:
ResourceException - Exception raised in failure situation

getCheckedOutResources

public IResourceList getCheckedOutResources()
                                     throws ResourceException
Returns:
set of current checkouts of this version
Throws:
ResourceException

getCheckInForkBehaviour

public Set getCheckInForkBehaviour()
                            throws ResourceException
Returns:
a set of INames describing the checkout-in behaviour for this resource.
Throws:
ResourceException - Exception raised in failure situation
See Also:
FORKBEHAVIOUR_DISCOURAGED, FORKBEHAVIOUR_FORBIDDEN

getCheckOutForkBehaviour

public Set getCheckOutForkBehaviour()
                             throws ResourceException
Returns:
a set of INames describing the checkout-fork behaviour for this resource.
Throws:
ResourceException - Exception raised in failure situation
See Also:
FORKBEHAVIOUR_DISCOURAGED, FORKBEHAVIOUR_FORBIDDEN

getCheckedOutRIDs

public IRidSet getCheckedOutRIDs()
                          throws ResourceException
Returns:
set of current checkouts of this version
Throws:
ResourceException

getPredecessorResources

public IResourceList getPredecessorResources()
                                      throws ResourceException
Returns:
set of immediate predecessors if this version
Throws:
ResourceException

getPredecessorRIDs

public IRidSet getPredecessorRIDs()
                           throws ResourceException
Returns:
set of immediate predecessors if this version
Throws:
ResourceException

getVersionHistoryResource

public IResource getVersionHistoryResource()
                                    throws ResourceException
Returns:
IResource for version history resource (or null if version history resources are not supported).
Throws:
ResourceException

getVersionHistoryRID

public RID getVersionHistoryRID()
                         throws ResourceException
Returns:
RID of version history resource (or null if version history resources are not supported).
Throws:
ResourceException

getSuccessorResources

public IResourceList getSuccessorResources()
                                    throws ResourceException
Returns:
set of immediate successors of this version
Throws:
ResourceException

getSuccessorRIDs

public IRidSet getSuccessorRIDs()
                         throws ResourceException
Returns:
set of immediate successors of this version
Throws:
ResourceException

addLabel

public void addLabel(String labelName)
              throws ResourceException
Adds the given label if and only if it didn't exist before in the version's version history.

Parameters:
labelName - label
Throws:
ResourceException - Exception raised in failure situation

setLabel

public void setLabel(String labelName)
              throws ResourceException
Sets the given label on the version (removing it from other versions if present)

Parameters:
labelName - label
Throws:
ResourceException - Exception raised in failure situation

removeLabel

public void removeLabel(String labelName)
                 throws ResourceException
Removes the given label from the resource if present (removing non-existing labels should be signaled through an exception)

Parameters:
labelName - label
Throws:
ResourceException - Exception raised in failure situation

getLabelSet

public Set getLabelSet()
                throws ResourceException
Returns:
set of labels present on this version (empty list when no labels present).
Throws:
ResourceException - Exception raised in failure situation


Copyright 2006 SAP AG. All rights reserved. No part of this publication may be reproduced or transmitted in any form or for any purpose without the express permission of SAP AG. The information contained herein may be changed without prior notice. Microsoft, Windows, Outlook, and PowerPoint are registered trademarks of Microsoft Corporation. Oracle is a registered trademark of Oracle Corporation. UNIX, X/Open, OSF/1, and Motif are registered trademarks of the Open Group. Citrix, ICA, Program Neighborhood, MetaFrame, WinFrame, VideoFrame, and MultiWin are trademarks or registered trademarks of Citrix Systems, Inc. HTML, XML, XHTML and W3C are trademarks or registered trademarks of W3C, World Wide Web Consortium, Massachusetts Institute of Technology. Java is a registered trademark of Sun Microsystems, Inc. JavaScript is a registered trademark of Sun Microsystems, Inc., used under license for technology invented and implemented by Netscape. MaxDB is a trademark of MySQL AB, Sweden. SAP, R/3, mySAP, mySAP.com, xApps, xApp, SAP NetWeaver, and other SAP products and services mentioned herein as well as their respective logos are trademarks or registered trademarks of SAP AG in Germany and in several other countries all over the world. All other product and service names mentioned are the trademarks of their respective companies. Data contained in this document serves informational purposes only. National product specifications may vary. These materials are subject to change without notice. These materials are provided by SAP AG and its affiliated companies ("SAP Group") for informational purposes only, without representation or warranty of any kind, and SAP Group shall not be liable for errors or omissions with respect to the materials. The only warranties for SAP Group products and services are those that are set forth in the express warranty statements accompanying such products and services, if any. Nothing herein should be construed as constituting an additional warranty.