throw new IllegalArgumentException( "The element [type=\"" + typeName + "\"," + "location=\"" + location + "\"] must have name defined." ); }
iter = noNameList.iterator( ); while ( iter.hasNext( ) ) { DesignElementHandle contentHandle = (DesignElementHandle) iter .next( ); if ( !genDefaultName ) { String typeName = contentHandle.getDefn( ).getDisplayName( ); String location = contentHandle.getElement( ) .getIdentifier( );
	void exportDesign( ReportDesignHandle designToExport, boolean canOverride,			boolean genDefaultName ) throws SemanticException	{		ModelUtil.duplicateProperties( designToExport, targetLibraryHandle,				false );		// Copy the contents in design file.		int slotCount = designToExport.getDefn( ).getSlotCount( );		for ( int i = 0; i < slotCount; i++ )		{			SlotHandle sourceSlotHandle = designToExport.getSlot( i );			Iterator iter = sourceSlotHandle.iterator( );			while ( iter.hasNext( ) )			{				DesignElementHandle contentHandle = (DesignElementHandle) iter						.next( );				if ( StringUtil.isBlank( contentHandle.getName( ) ) )				{					if ( !genDefaultName )					{						String typeName = contentHandle.getDefn( )								.getDisplayName( );						String location = contentHandle.getElement( )								.getIdentifier( );						throw new IllegalArgumentException(								"The element [type=\"" + typeName + "\"," //$NON-NLS-1$//$NON-NLS-2$ 										+ "location=\"" + location + "\"] must have name defined." ); //$NON-NLS-1$ //$NON-NLS-2$					}					targetLibraryHandle.getModule( ).makeUniqueName(							contentHandle.getElement( ) );				}				exportElement( contentHandle, canOverride );			}		}	}