#NEWLINE# def define_enclosure_group( net , srv , name , lname ) : #NEWLINE# #INDENT# ligs = net . get_ligs ( ) #NEWLINE# for lig in ligs : #NEWLINE# #INDENT# if ( lig [ 'name' ] == lname ) : #NEWLINE# #INDENT# print ( 'Creating Enclosure Group' ) #NEWLINE# egroup = srv . create_enclosure_group ( lig , name ) #NEWLINE# if ( 'name' in egroup ) : #NEWLINE# #INDENT# print ( 'Name:          ' , egroup [ 'name' ] ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# pprint ( egroup ) #NEWLINE# #UNINDENT# #UNINDENT# else : #NEWLINE# #INDENT# print ( 'ERROR: Creating Enclosure Group' ) #NEWLINE# print ( ( 'LIG: "%s" has not been defined' % lname ) ) #NEWLINE# print ( '' )