# 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 ClientsCommand(object): """ NOTE: This class is auto generated by the swagger code generator program. Do not edit the class manually. """ def __init__(self): """ ClientsCommand - 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 = { 'client': 'str', 'owner': 'str', 'update': 'datetime', 'access': 'datetime', 'host': 'str', 'description': 'str', 'root': 'str', 'type': 'str', 'options': 'str', 'submit_options': 'str', 'line_end': 'str', 'stream': 'str' } self.attribute_map = { 'client': 'client', 'owner': 'owner', 'update': 'update', 'access': 'access', 'host': 'host', 'description': 'description', 'root': 'root', 'type': 'type', 'options': 'options', 'submit_options': 'submitOptions', 'line_end': 'lineEnd', 'stream': 'stream' } self._client = None self._owner = None self._update = None self._access = None self._host = None self._description = None self._root = None self._type = None self._options = None self._submit_options = None self._line_end = None self._stream = None @property def client(self): """ Gets the client of this ClientsCommand. The client workspace name, as specified in the `P4CLIENT` environment variable or its equivalents. :return: The client of this ClientsCommand. :rtype: str """ return self._client @client.setter def client(self, client): """ Sets the client of this ClientsCommand. The client workspace name, as specified in the `P4CLIENT` environment variable or its equivalents. :param client: The client of this ClientsCommand. :type: str """ self._client = client @property def owner(self): """ Gets the owner of this ClientsCommand. The name of the user who owns the workspace.\nThe default is the user who created the workspace.\n\nThe specified owner does not have to be a Perforce user.\nYou might want to use an arbitrary name if the user does not yet exist, or if you have deleted the user and need a placeholder until you can assign the spec to a new user. :return: The owner of this ClientsCommand. :rtype: str """ return self._owner @owner.setter def owner(self, owner): """ Sets the owner of this ClientsCommand. The name of the user who owns the workspace.\nThe default is the user who created the workspace.\n\nThe specified owner does not have to be a Perforce user.\nYou might want to use an arbitrary name if the user does not yet exist, or if you have deleted the user and need a placeholder until you can assign the spec to a new user. :param owner: The owner of this ClientsCommand. :type: str """ self._owner = owner @property def update(self): """ Gets the update of this ClientsCommand. The time the workspace specification was last modified. :return: The update of this ClientsCommand. :rtype: datetime """ return self._update @update.setter def update(self, update): """ Sets the update of this ClientsCommand. The time the workspace specification was last modified. :param update: The update of this ClientsCommand. :type: datetime """ self._update = update @property def access(self): """ Gets the access of this ClientsCommand. The date and time that the workspace was last used in any way.\n(Note: Reloading a workspace with p4 reload does not affect the access time.) :return: The access of this ClientsCommand. :rtype: datetime """ return self._access @access.setter def access(self, access): """ Sets the access of this ClientsCommand. The date and time that the workspace was last used in any way.\n(Note: Reloading a workspace with p4 reload does not affect the access time.) :param access: The access of this ClientsCommand. :type: datetime """ self._access = access @property def host(self): """ Gets the host of this ClientsCommand. The name of the workstation on which this workspace resides.\nIf included, operations on this client workspace can be run only from this host.\nIf not set, access is allowed from any host.\n\nThe hostname must be provided exactly as it appears in the output of p4 info when run from that host.\n\nThis field is meant to prevent accidental misuse of client workspaces on the wrong machine.\nProviding a host name does not guarantee security, because the actual value of the host name can be overridden with the -H option to any p4 command, or with the P4HOST environment variable.\nFor a similar mechanism that does provide security, use the IP address restriction feature of p4 protect. :return: The host of this ClientsCommand. :rtype: str """ return self._host @host.setter def host(self, host): """ Sets the host of this ClientsCommand. The name of the workstation on which this workspace resides.\nIf included, operations on this client workspace can be run only from this host.\nIf not set, access is allowed from any host.\n\nThe hostname must be provided exactly as it appears in the output of p4 info when run from that host.\n\nThis field is meant to prevent accidental misuse of client workspaces on the wrong machine.\nProviding a host name does not guarantee security, because the actual value of the host name can be overridden with the -H option to any p4 command, or with the P4HOST environment variable.\nFor a similar mechanism that does provide security, use the IP address restriction feature of p4 protect. :param host: The host of this ClientsCommand. :type: str """ self._host = host @property def description(self): """ Gets the description of this ClientsCommand. A textual description of the workspace. The default text is Created by owner. :return: The description of this ClientsCommand. :rtype: str """ return self._description @description.setter def description(self, description): """ Sets the description of this ClientsCommand. A textual description of the workspace. The default text is Created by owner. :param description: The description of this ClientsCommand. :type: str """ self._description = description @property def root(self): """ Gets the root of this ClientsCommand. The directory (on the local host) relative to which all the files in the `View:` are specified.\nThe default is the current working directory.\nThe path must be specified in local file system syntax.\n\nIf you change this setting, you must physically relocate any files that currently reside there.\nOn Windows client machines, you can specify the root as null to enable you to map files to multiple drives. additionalProperties: :return: The root of this ClientsCommand. :rtype: str """ return self._root @root.setter def root(self, root): """ Sets the root of this ClientsCommand. The directory (on the local host) relative to which all the files in the `View:` are specified.\nThe default is the current working directory.\nThe path must be specified in local file system syntax.\n\nIf you change this setting, you must physically relocate any files that currently reside there.\nOn Windows client machines, you can specify the root as null to enable you to map files to multiple drives. additionalProperties: :param root: The root of this ClientsCommand. :type: str """ self._root = root @property def type(self): """ Gets the type of this ClientsCommand. By default clients are writeable.\nSpecify readonly for short lived clients used in build automation scripts.\nSuch clients cannot edit or submit files, but this should not be an issue in build scripts.\n\nUsing writeable clients in build automation scripts can lead to db.have table fragmentation, which is used to track what files a client has synced.\nIf you are experiencing such issues, use a read-only client instead.\nA readonly client is assigned its own personal db.have database table.\nThe location of this table must first be specified by an administrator with the client.readonly.dir configurable. :return: The type of this ClientsCommand. :rtype: str """ return self._type @type.setter def type(self, type): """ Sets the type of this ClientsCommand. By default clients are writeable.\nSpecify readonly for short lived clients used in build automation scripts.\nSuch clients cannot edit or submit files, but this should not be an issue in build scripts.\n\nUsing writeable clients in build automation scripts can lead to db.have table fragmentation, which is used to track what files a client has synced.\nIf you are experiencing such issues, use a read-only client instead.\nA readonly client is assigned its own personal db.have database table.\nThe location of this table must first be specified by an administrator with the client.readonly.dir configurable. :param type: The type of this ClientsCommand. :type: str """ self._type = type @property def options(self): """ Gets the options of this ClientsCommand. A set of seven switches that control particular workspace options.\n\nSee [Usage Notes](https://www.perforce.com/perforce/doc.current/manuals/cmdref/p4_client.html#p4_client.usage) for a listing of these options. :return: The options of this ClientsCommand. :rtype: str """ return self._options @options.setter def options(self, options): """ Sets the options of this ClientsCommand. A set of seven switches that control particular workspace options.\n\nSee [Usage Notes](https://www.perforce.com/perforce/doc.current/manuals/cmdref/p4_client.html#p4_client.usage) for a listing of these options. :param options: The options of this ClientsCommand. :type: str """ self._options = options @property def submit_options(self): """ Gets the submit_options of this ClientsCommand. Options to govern the default behavior of p4 submit.\n\n* submitunchanged\n+\nAll open files (with or without changes) are submitted to the depot. This is the default behavior of Perforce.\n\n* submitunchanged+reopen\n+\nAll open files (with or without changes) are submitted to the depot, and all files are automatically reopened in the default changelist.\n\n* revertunchanged\n+\nOnly those files with content, type, or resolved changes are submitted to the depot. Unchanged files are reverted.\n\n* revertunchanged+reopen\n+\nOnly those files with content, type, or resolved changes are submitted to the depot and reopened in the default changelist. Unchanged files are reverted and not reopened in the default changelist.\n\n* leaveunchanged\n+\nOnly those files with content, type, or resolved changes are submitted to the depot. Any unchanged files are moved to the default changelist.\n\n* leaveunchanged+reopen\n+\nOnly those files with content, type, or resolved changes are submitted to the depot. Unchanged files are moved to the default changelist, and changed files are reopened in the default changelist. This option is similar to submitunchanged+reopen, except that no unchanged files are submitted to the depot. :return: The submit_options of this ClientsCommand. :rtype: str """ return self._submit_options @submit_options.setter def submit_options(self, submit_options): """ Sets the submit_options of this ClientsCommand. Options to govern the default behavior of p4 submit.\n\n* submitunchanged\n+\nAll open files (with or without changes) are submitted to the depot. This is the default behavior of Perforce.\n\n* submitunchanged+reopen\n+\nAll open files (with or without changes) are submitted to the depot, and all files are automatically reopened in the default changelist.\n\n* revertunchanged\n+\nOnly those files with content, type, or resolved changes are submitted to the depot. Unchanged files are reverted.\n\n* revertunchanged+reopen\n+\nOnly those files with content, type, or resolved changes are submitted to the depot and reopened in the default changelist. Unchanged files are reverted and not reopened in the default changelist.\n\n* leaveunchanged\n+\nOnly those files with content, type, or resolved changes are submitted to the depot. Any unchanged files are moved to the default changelist.\n\n* leaveunchanged+reopen\n+\nOnly those files with content, type, or resolved changes are submitted to the depot. Unchanged files are moved to the default changelist, and changed files are reopened in the default changelist. This option is similar to submitunchanged+reopen, except that no unchanged files are submitted to the depot. :param submit_options: The submit_options of this ClientsCommand. :type: str """ self._submit_options = submit_options @property def line_end(self): """ Gets the line_end of this ClientsCommand. Configure carriage-return/linefeed (CR/LF) conversion.\n\nSee [Usage Notes](https://www.perforce.com/perforce/doc.current/manuals/cmdref/p4_client.html#p4_client.usage) for a listing of these options. :return: The line_end of this ClientsCommand. :rtype: str """ return self._line_end @line_end.setter def line_end(self, line_end): """ Sets the line_end of this ClientsCommand. Configure carriage-return/linefeed (CR/LF) conversion.\n\nSee [Usage Notes](https://www.perforce.com/perforce/doc.current/manuals/cmdref/p4_client.html#p4_client.usage) for a listing of these options. :param line_end: The line_end of this ClientsCommand. :type: str """ self._line_end = line_end @property def stream(self): """ Gets the stream of this ClientsCommand. Associates the workspace with the specified stream.\n\nPerforce generates the view for stream-associated workspaces: you cannot modify it manually. :return: The stream of this ClientsCommand. :rtype: str """ return self._stream @stream.setter def stream(self, stream): """ Sets the stream of this ClientsCommand. Associates the workspace with the specified stream.\n\nPerforce generates the view for stream-associated workspaces: you cannot modify it manually. :param stream: The stream of this ClientsCommand. :type: str """ self._stream = stream 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