tmp/src/things/things.py
def updateLogicalInterface(self, logicalInterfaceId, name, schemaId, description=None):
        """
        Updates a logical interface.
        Parameters: logicalInterfaceId (string), name (string), schemaId (string), description (string, optional).
        Throws APIException on failure.
        """
        req = ApiClient.oneLogicalInterfaceUrl % (self.host, "/draft", logicalInterfaceId)
        body = {"name" : name, "schemaId" : schemaId, "id" : logicalInterfaceId}
        if description:
            body["description"] = description
        resp = requests.put(req, auth=self.credentials, headers={"Content-Type":"application/json"},
                            data=json.dumps(body),  verify=self.verify)
        if resp.status_code == 200:
            self.logger.debug("Logical interface updated")
        else:
            raise ibmiotf.APIException(resp.status_code, "HTTP error updating logical interface", resp)
        return resp.json()
def updateLogicalInterface(self, logicalInterfaceId, name, schemaId, description=None):
        """
        Updates a logical interface.
        Parameters: logicalInterfaceId (string), name (string), schemaId (string), description (string, optional).
        Throws APIException on failure.
        """
        req = ApiClient.oneLogicalInterfaceUrl % (self.host, "/draft", logicalInterfaceId)
        body = {"name" : name, "schemaId" : schemaId, "id" : logicalInterfaceId}
        if description:
            body["description"] = description
        resp = requests.put(req, auth=self.credentials, headers={"Content-Type":"application/json"},
                            data=json.dumps(body),  verify=self.verify)
        if resp.status_code == 200:
            self.logger.debug("Logical interface updated")
        else:
            raise ibmiotf.APIException(resp.status_code, "HTTP error updating logical interface", resp)
        return resp.json()
def updateLogicalInterface ( self , logicalInterfaceId , name , schemaId , description = None ) : req = ApiClient . oneLogicalInterfaceUrl % ( self . host , "/draft" , logicalInterfaceId ) body = { "name" : name , "schemaId" : schemaId , "id" : logicalInterfaceId } if description : body [ "description" ] = description resp = requests . put ( req , auth = self . credentials , headers = { "Content-Type" : "application/json" } , data = json . dumps ( body ) , verify = self . verify ) if resp . status_code == 200 : self . logger . debug ( "Logical interface updated" ) else : raise ibmiotf . APIException ( resp . status_code , "HTTP error updating logical interface" , resp ) return resp . json ( )
Updates a logical interface.
        Parameters: logicalInterfaceId (string), name (string), schemaId (string), description (string, optional).
        Throws APIException on failure.
Updates a logical interface . Parameters : logicalInterfaceId ( string ) name ( string ) schemaId ( string ) description ( string optional ) . Throws APIException on failure .