# coding: utf-8 """ Copyright 2015 SmartBear Software Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. Ref: https://github.com/swagger-api/swagger-codegen """ from pprint import pformat from six import iteritems class DepotsCommand(object): """ NOTE: This class is auto generated by the swagger code generator program. Do not edit the class manually. """ def __init__(self): """ DepotsCommand - a model defined in Swagger :param dict swaggerTypes: The key is attribute name and the value is attribute type. :param dict attributeMap: The key is attribute name and the value is json key in definition. """ self.swagger_types = { 'depot': 'str', 'map': 'str', 'type': 'str', 'stream_depth': 'str', 'description': 'str' } self.attribute_map = { 'depot': 'depot', 'map': 'map', 'type': 'type', 'stream_depth': 'streamDepth', 'description': 'description' } self._depot = None self._map = None self._type = None self._stream_depth = None self._description = None @property def depot(self): """ Gets the depot of this DepotsCommand. The depot name. :return: The depot of this DepotsCommand. :rtype: str """ return self._depot @depot.setter def depot(self, depot): """ Sets the depot of this DepotsCommand. The depot name. :param depot: The depot of this DepotsCommand. :type: str """ self._depot = depot @property def map(self): """ Gets the map of this DepotsCommand. If the Type: is local, spec, or archive, set the map to point to the relative location of the depot subdirectory.\nThe map must contain the `...` wildcard; for example, a local depot new might have a Map: of `new/...`.\n\nIf the Type: is remote, set the map to point to a location in the remote depot's physical namespace, for example, `//depot/new/rel2/...`.\nThis directory will be the root of the local representation of the remote depot. :return: The map of this DepotsCommand. :rtype: str """ return self._map @map.setter def map(self, map): """ Sets the map of this DepotsCommand. If the Type: is local, spec, or archive, set the map to point to the relative location of the depot subdirectory.\nThe map must contain the `...` wildcard; for example, a local depot new might have a Map: of `new/...`.\n\nIf the Type: is remote, set the map to point to a location in the remote depot's physical namespace, for example, `//depot/new/rel2/...`.\nThis directory will be the root of the local representation of the remote depot. :param map: The map of this DepotsCommand. :type: str """ self._map = map @property def type(self): """ Gets the type of this DepotsCommand. `local`, `remote`, `spec`, `stream`, `unload`, `archive` or `tangent`.\n\nA local depot is writable, and is the default depot type.\nFiles reside in the server's root directory and are managed directly by the server.\n\nA stream depot is also writable, but contains streams, a type of branch that includes hierarchy and policy.\n\nA remote depot references files that reside on other servers, and cannot be written to.\n\nThe spec depot, if present, automatically archives edited forms.\n\nThe unload depot, if present, holds infrequently-used metadata (about old client workspaces and labels) that has been unloaded with the p4 unload command.\n\nAn archive depot is used in conjunction with the p4 archive and p4 restore commands to facilitate offline (or near-line) storage of infrequently-accessed revisions, typically large binaries.\n\nA tangent depot defines a read-only location that holds tangents created by the p4 fetch -t command.\nThe tangent depot named tangent is automatically created by p4 fetch -t if one does not already exist. :return: The type of this DepotsCommand. :rtype: str """ return self._type @type.setter def type(self, type): """ Sets the type of this DepotsCommand. `local`, `remote`, `spec`, `stream`, `unload`, `archive` or `tangent`.\n\nA local depot is writable, and is the default depot type.\nFiles reside in the server's root directory and are managed directly by the server.\n\nA stream depot is also writable, but contains streams, a type of branch that includes hierarchy and policy.\n\nA remote depot references files that reside on other servers, and cannot be written to.\n\nThe spec depot, if present, automatically archives edited forms.\n\nThe unload depot, if present, holds infrequently-used metadata (about old client workspaces and labels) that has been unloaded with the p4 unload command.\n\nAn archive depot is used in conjunction with the p4 archive and p4 restore commands to facilitate offline (or near-line) storage of infrequently-accessed revisions, typically large binaries.\n\nA tangent depot defines a read-only location that holds tangents created by the p4 fetch -t command.\nThe tangent depot named tangent is automatically created by p4 fetch -t if one does not already exist. :param type: The type of this DepotsCommand. :type: str """ self._type = type @property def stream_depth(self): """ Gets the stream_depth of this DepotsCommand. For stream depots, the optional depth to be used for stream paths in the depot, where depth specifies the number of slashes following the depot name of a stream. ]\n\nThis field is used when streams are being created.\nThe default is 1, matching the traditional stream name.\nYou cannot update this value once streams or archive data exist in a depot. :return: The stream_depth of this DepotsCommand. :rtype: str """ return self._stream_depth @stream_depth.setter def stream_depth(self, stream_depth): """ Sets the stream_depth of this DepotsCommand. For stream depots, the optional depth to be used for stream paths in the depot, where depth specifies the number of slashes following the depot name of a stream. ]\n\nThis field is used when streams are being created.\nThe default is 1, matching the traditional stream name.\nYou cannot update this value once streams or archive data exist in a depot. :param stream_depth: The stream_depth of this DepotsCommand. :type: str """ self._stream_depth = stream_depth @property def description(self): """ Gets the description of this DepotsCommand. A short description of the depot’s purpose. Optional. :return: The description of this DepotsCommand. :rtype: str """ return self._description @description.setter def description(self, description): """ Sets the description of this DepotsCommand. A short description of the depot’s purpose. Optional. :param description: The description of this DepotsCommand. :type: str """ self._description = description def to_dict(self): """ Returns the model properties as a dict """ result = {} for attr, _ in iteritems(self.swagger_types): value = getattr(self, attr) if isinstance(value, list): result[attr] = list(map( lambda x: x.to_dict() if hasattr(x, "to_dict") else x, value )) elif hasattr(value, "to_dict"): result[attr] = value.to_dict() else: result[attr] = value return result def to_str(self): """ Returns the string representation of the model """ return pformat(self.to_dict()) def __repr__(self): """ For `print` and `pprint` """ return self.to_str() def __eq__(self, other): """ Returns true if both objects are equal """ return self.__dict__ == other.__dict__ def __ne__(self, other): """ Returns true if both objects are not equal """ return not self == other