Class DepotDelegator

java.lang.Object
com.perforce.p4java.impl.mapbased.server.cmd.BaseDelegator
com.perforce.p4java.impl.mapbased.server.cmd.DepotDelegator
All Implemented Interfaces:
IDepotDelegator

public class DepotDelegator extends BaseDelegator implements IDepotDelegator
DepotDelegator implementation.
  • Constructor Details

    • DepotDelegator

      public DepotDelegator(IOptionsServer server)
      Instantiates a new depot delegator.
      Parameters:
      server - the server
  • Method Details

    • createDepot

      public String createDepot(@Nonnull IDepot newDepot) throws P4JavaException
      Description copied from interface: IDepotDelegator
      Create a new depot in the repository. You must be an admin for this operation to succeed.
      Specified by:
      createDepot in interface IDepotDelegator
      Parameters:
      newDepot - non-null IDepot object representing the depot to be created.
      Returns:
      possibly-null operation result message string from the Perforce server.
      Throws:
      P4JavaException - if any error occurs in the processing of this method.
    • deleteDepot

      public String deleteDepot(String name) throws P4JavaException
      Description copied from interface: IDepotDelegator
      Delete a named depot from the repository. You must be an admin for this operation to succeed.
      Specified by:
      deleteDepot in interface IDepotDelegator
      Parameters:
      name - non-null IDepot object representing the depot to be deleted
      Returns:
      possibly-null operation result message string from the Perforce server.
      Throws:
      P4JavaException - if any error occurs in the processing of this method.
    • getDepot

      public IDepot getDepot(String name) throws P4JavaException
      Description copied from interface: IDepotDelegator
      Get an individual depot by name. Note that this method will return a fake depot if you ask it for a non-existent depot, so it's not the most useful of operations.
      Specified by:
      getDepot in interface IDepotDelegator
      Parameters:
      name - non-null name of the depot to be retrieved.
      Returns:
      IDepot non-null object corresponding to the named depot if it exists and is retrievable; otherwise an IDepot object that looks real but does not, in fact, correspond to any known depot in the repository.
      Throws:
      P4JavaException - if any error occurs in the processing of this method.