#NEWLINE# def create_masking_view( self , masking ) : #NEWLINE# #INDENT# config_service = masking [ 'controllerConfigService' ] #NEWLINE# masking_view_name = masking [ 'maskingViewName' ] #NEWLINE# initiator_masking_group = self . _find_or_create_initiator_group ( masking ) #NEWLINE# port_group = self . _find_port_group ( masking ) #NEWLINE# masking_group = self . _find_or_create_device_masking_group ( masking ) #NEWLINE# if ( port_group and masking_group and initiator_masking_group and masking_view_name ) : #NEWLINE# #INDENT# ( rc , job ) = self . connection . InvokeMethod ( 'CreateMaskingView' , config_service , ElementName = masking_view_name , InitiatorMaskingGroup = initiator_masking_group , DeviceMaskingGroup = masking_group , TargetMaskingGroup = port_group ) #NEWLINE# self . _wait_job_completion ( rc , job ) #NEWLINE# created_masking_view = self . connection . AssociatorNames ( job [ 'Job' ] , ResultClass = 'Symm_LunMaskingView' ) #NEWLINE# if created_masking_view : #NEWLINE# #INDENT# return created_masking_view [ 0 ]