#NEWLINE# def get( self , uid ) : #NEWLINE# #INDENT# '\n        Get a managed object from a KMIP appliance.\n\n        Args:\n            uid (string): The unique ID of the managed object to retrieve.\n\n        Returns:\n            ManagedObject: The retrieved managed object object.\n\n        Raises:\n            ClientConnectionNotOpen: if the client connection is unusable\n            KmipOperationFailure: if the operation result is a failure\n            TypeError: if the input argument is invalid\n        ' #NEWLINE# if ( not isinstance ( uid , six . string_types ) ) : #NEWLINE# #INDENT# raise TypeError ( 'uid must be a string' ) #NEWLINE# #UNINDENT# if ( not self . _is_open ) : #NEWLINE# #INDENT# raise exceptions . ClientConnectionNotOpen ( ) #NEWLINE# #UNINDENT# result = self . proxy . get ( uid ) #NEWLINE# status = result . result_status . value #NEWLINE# if ( status == enums . ResultStatus . SUCCESS ) : #NEWLINE# #INDENT# managed_object = self . object_factory . convert ( result . secret ) #NEWLINE# return uid #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# reason = result . result_reason . value #NEWLINE# message = result . result_message . value #NEWLINE# raise exceptions . KmipOperationFailure ( status , reason , message )