Class Depot
- java.lang.Object
-
- com.perforce.p4java.impl.generic.core.ServerResource
-
- com.perforce.p4java.impl.generic.core.Depot
-
- All Implemented Interfaces:
IDepot
,IServerResource
public class Depot extends ServerResource implements IDepot
Simple default implementation class for the IDepot interface.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface com.perforce.p4java.core.IDepot
IDepot.DepotType
-
-
Field Summary
-
Fields inherited from class com.perforce.p4java.impl.generic.core.ServerResource
refreshable, server, updateable
-
-
Constructor Summary
Constructors Constructor Description Depot()
Depot(java.lang.String name, java.lang.String ownerName, java.util.Date modDate, java.lang.String description, IDepot.DepotType depotType, java.lang.String address, java.lang.String suffix, java.lang.String map)
Depot(java.lang.String name, java.lang.String ownerName, java.util.Date modDate, java.lang.String description, IDepot.DepotType depotType, java.lang.String address, java.lang.String suffix, java.lang.String streamDepth, java.lang.String map)
Depot(java.lang.String name, java.lang.String ownerName, java.util.Date modDate, java.lang.String description, IDepot.DepotType depotType, java.lang.String address, java.lang.String suffix, java.lang.String streamDepth, java.lang.String map, ViewMap<IMapEntry> specMap)
Depot(java.util.Map<java.lang.String,java.lang.Object> depotMap)
Construct a Perforce depot object from a suitable depotMap passed back from the Perforce server as the result of a depot list command.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getAddress()
For remote depots, return the (remote) address of the depot; for other types of depot, will return null.IDepot.DepotType
getDepotType()
Get the type of this depot.java.lang.String
getDescription()
Get the description associated with this depot.java.lang.String
getMap()
Get the depot's path translation information.java.util.Date
getModDate()
Get the date the depot was last modified.java.lang.String
getName()
Get the name of the depot.java.lang.String
getOwnerName()
Get the Perforce user name of the depot's owner.ViewMap<IMapEntry>
getSpecMap()
For spec depots, the optional description of which specs should be saved, as one or more patterns.java.lang.String
getStreamDepth()
For stream depots, the optional depth to be used for stream paths in the depot, where depth equates to the number of slashes following the depot name of a stream.java.lang.String
getSuffix()
For spec depots, the optional suffix to be used for generated paths.void
setAddress(java.lang.String address)
void
setDepotType(IDepot.DepotType depotType)
void
setDescription(java.lang.String description)
void
setMap(java.lang.String map)
void
setModDate(java.util.Date modDate)
void
setName(java.lang.String name)
void
setOwnerName(java.lang.String ownerName)
void
setSpecMap(ViewMap<IMapEntry> specMap)
void
setStreamDepth(java.lang.String streamDepth)
void
setSuffix(java.lang.String suffix)
-
Methods inherited from class com.perforce.p4java.impl.generic.core.ServerResource
canRefresh, canUpdate, clearRawFields, complete, getRawField, getRawFields, hasRawField, parseDate, refresh, setRawField, setRawFields, setRefreshable, setServer, toDateString, update, update, update
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.perforce.p4java.core.IServerResource
canRefresh, canUpdate, clearRawFields, complete, getRawField, getRawFields, hasRawField, refresh, setRawField, setRawFields, setServer, update, update, update
-
-
-
-
Constructor Detail
-
Depot
public Depot()
-
Depot
public Depot(java.util.Map<java.lang.String,java.lang.Object> depotMap)
Construct a Perforce depot object from a suitable depotMap passed back from the Perforce server as the result of a depot list command.- Parameters:
depotMap
- depotMap passed back from the Perforce server as a result of the depot list or depot -o commands; if null, fields will have default values.
-
Depot
public Depot(java.lang.String name, java.lang.String ownerName, java.util.Date modDate, java.lang.String description, IDepot.DepotType depotType, java.lang.String address, java.lang.String suffix, java.lang.String map)
-
Depot
public Depot(java.lang.String name, java.lang.String ownerName, java.util.Date modDate, java.lang.String description, IDepot.DepotType depotType, java.lang.String address, java.lang.String suffix, java.lang.String streamDepth, java.lang.String map)
-
Depot
public Depot(java.lang.String name, java.lang.String ownerName, java.util.Date modDate, java.lang.String description, IDepot.DepotType depotType, java.lang.String address, java.lang.String suffix, java.lang.String streamDepth, java.lang.String map, ViewMap<IMapEntry> specMap)
-
-
Method Detail
-
getAddress
public java.lang.String getAddress()
Description copied from interface:IDepot
For remote depots, return the (remote) address of the depot; for other types of depot, will return null.- Specified by:
getAddress
in interfaceIDepot
- Returns:
- address
-
setAddress
public void setAddress(java.lang.String address)
-
getDepotType
public IDepot.DepotType getDepotType()
Description copied from interface:IDepot
Get the type of this depot.- Specified by:
getDepotType
in interfaceIDepot
- Returns:
- type
-
setDepotType
public void setDepotType(IDepot.DepotType depotType)
-
getDescription
public java.lang.String getDescription()
Description copied from interface:IDepot
Get the description associated with this depot.- Specified by:
getDescription
in interfaceIDepot
- Returns:
- description
-
setDescription
public void setDescription(java.lang.String description)
-
getMap
public java.lang.String getMap()
Description copied from interface:IDepot
Get the depot's path translation information.
-
setMap
public void setMap(java.lang.String map)
-
getModDate
public java.util.Date getModDate()
Description copied from interface:IDepot
Get the date the depot was last modified.- Specified by:
getModDate
in interfaceIDepot
- Returns:
- date
-
setModDate
public void setModDate(java.util.Date modDate)
-
getName
public java.lang.String getName()
Description copied from interface:IDepot
Get the name of the depot.
-
setName
public void setName(java.lang.String name)
-
getOwnerName
public java.lang.String getOwnerName()
Description copied from interface:IDepot
Get the Perforce user name of the depot's owner.- Specified by:
getOwnerName
in interfaceIDepot
- Returns:
- owner
-
setOwnerName
public void setOwnerName(java.lang.String ownerName)
-
getSpecMap
public ViewMap<IMapEntry> getSpecMap()
Description copied from interface:IDepot
For spec depots, the optional description of which specs should be saved, as one or more patterns. See example below.//spec/... -//spec/user/qa-* -//spec/client/qa-*
- Specified by:
getSpecMap
in interfaceIDepot
- Returns:
- view mapping
-
getStreamDepth
public java.lang.String getStreamDepth()
Description copied from interface:IDepot
For stream depots, the optional depth to be used for stream paths in the depot, where depth equates to the number of slashes following the depot name of a stream. This field is referenced when streams are being created. The default is '1', matching the traditional stream name. For example, "//stream_test/1". This value may not be updated once streams or archive data exist within the depot.- Specified by:
getStreamDepth
in interfaceIDepot
- Returns:
- stream depth
-
setStreamDepth
public void setStreamDepth(java.lang.String streamDepth)
-
getSuffix
public java.lang.String getSuffix()
Description copied from interface:IDepot
For spec depots, the optional suffix to be used for generated paths. The default is '.p4s'.
-
setSuffix
public void setSuffix(java.lang.String suffix)
-
-