pub struct Depots<M = Unselected> { /* private fields */ }Expand description
p4 [g-opts] depots [[-e | -E] nameFilter] [-t type] [-a]
Display a list of depots known to the P4 Server.
Display a list of depots.
The list excludes
- the default graph depot named
repounless you use thep4 depots -t graphcommand - the extension depot unless a user with the
superprotection uses thep4 depots -t extensioncommand
If a depot is excluded in the protections table for a given user, that user does not see the depot in the output of this command.
Operator users can run this command. (To learn about operator users, see the p4 user usage notes.)
The M type parameter tracks the command form at compile time. The
default Unselected state is the bare listing form with no local
options
; Self::depot_type and Self::list_all transition to the ListSpecified and ListAll modes.
Implementations§
Source§impl Depots<Unselected>
impl Depots<Unselected>
Sourcepub fn new(bin: impl Into<PathBuf>, global_opts: GlobalOpts) -> Self
pub fn new(bin: impl Into<PathBuf>, global_opts: GlobalOpts) -> Self
Creates a new p4 depots command.
bin is the path to the Perforce command-line executable.
Sourcepub fn depot_type(self, v: DepotType) -> Depots<ListSpecified>
pub fn depot_type(self, v: DepotType) -> Depots<ListSpecified>
§Description
-t type
List only the depots of the specified type.
Transitions this command to the ListSpecified mode.
Source§impl Depots<ListSpecified>
impl Depots<ListSpecified>
Sourcepub fn get_depot_type(&self) -> Option<DepotType>
pub fn get_depot_type(&self) -> Option<DepotType>
Sourcepub fn set_depot_type(&mut self, v: DepotType) -> &mut Self
pub fn set_depot_type(&mut self, v: DepotType) -> &mut Self
Sourcepub fn depot_type(self, v: DepotType) -> Self
pub fn depot_type(self, v: DepotType) -> Self
Source§impl<M: ExclusiveOption> Depots<M>
impl<M: ExclusiveOption> Depots<M>
Sourcepub fn set_filter(
&mut self,
v: impl Into<String>,
case_insensitive: bool,
) -> &mut Self
pub fn set_filter( &mut self, v: impl Into<String>, case_insensitive: bool, ) -> &mut Self
§Description
-e nameFilter
Lists depot specs with a name that matches the nameFilter pattern. p4 depots -e "h*x*" finds depots with names like helix and hxadm. If you use the * wildcard, enclose the search pattern in double quotes (“). This option follows the case-sensitivity of the server.
-E nameFilter
Makes the matching case-insensitive, even on a case-sensitive server.
The case_insensitive parameter selects -E over -e.
Sourcepub fn filter(self, v: impl Into<String>, case_insensitive: bool) -> Self
pub fn filter(self, v: impl Into<String>, case_insensitive: bool) -> Self
§Description
-e nameFilter
Lists depot specs with a name that matches the nameFilter pattern. p4 depots -e "h*x*" finds depots with names like helix and hxadm. If you use the * wildcard, enclose the search pattern in double quotes (“). This option follows the case-sensitivity of the server.
-E nameFilter
Makes the matching case-insensitive, even on a case-sensitive server.
The case_insensitive parameter selects -E over -e.