|| ( (PropertyDefn) propDefn ).getSubTypeCode( ) != PropertyType.ELEMENT_REF_TYPE )
|| ( (PropertyDefn) propDefn ).getSubTypeCode( ) != IPropertyType.ELEMENT_REF_TYPE )
	private List doCheckPropertyList( Module module, DesignElement element,			IPropertyDefn propDefn, List list, Object toAdd )	{		assert propDefn != null;		assert propDefn.getTypeCode( ) == PropertyType.LIST_TYPE;		if ( list == null				|| list.size( ) == 0				|| ( (PropertyDefn) propDefn ).getSubTypeCode( ) != PropertyType.ELEMENT_REF_TYPE )			return Collections.EMPTY_LIST;		List errorList = new ArrayList( );		// Get the unique member whose value should be unique in the		// structure list. The type of unique member is name property type.		// Note: The first unique member is considered.		HashSet values = new HashSet( );		for ( int i = 0; i < list.size( ); i++ )		{			ElementRefValue item = (ElementRefValue) list.get( i );			String key = item.getQualifiedReference( );			if ( values.contains( key ) )			{				errorList.add( new PropertyValueException( element, propDefn,						key,						PropertyValueException.DESIGN_EXCEPTION_VALUE_EXISTS ) );			}			else			{				values.add( key );			}		}		// check whether the toAdd is duplicate		if ( toAdd != null )		{			assert toAdd instanceof ElementRefValue;			String key = ( (ElementRefValue) toAdd ).getQualifiedReference( );			if ( values.contains( key ) )			{				errorList.add( new PropertyValueException( element, propDefn,						key,						PropertyValueException.DESIGN_EXCEPTION_VALUE_EXISTS ) );			}		}		return errorList;	}