DesignElement.PROPERTY_MASKS_PROP );
IDesignElementModel.PROPERTY_MASKS_PROP );
	public void setPropertyMask( String propName, String maskValue )			throws SemanticException	{		if ( DesignElement.PROPERTY_MASKS_PROP.equalsIgnoreCase( propName ) )			return;		ElementPropertyDefn maskProp = getElement( ).getPropertyDefn(				DesignElement.PROPERTY_MASKS_PROP );		if ( maskProp == null )		{			throw new PropertyNameException( element, propName );		}		ElementPropertyDefn prop = getElement( ).getPropertyDefn( propName );		if ( prop == null )			return;		ArrayList masks = (ArrayList) getElement( ).getLocalProperty(				getModule( ), DesignElement.PROPERTY_MASKS_PROP );		PropertyMask mask = null;		if ( masks == null )		{			masks = new ArrayList( );			getElement( )					.setProperty( DesignElement.PROPERTY_MASKS_PROP, masks );		}		for ( int i = 0; i < masks.size( ); i++ )		{			PropertyMask tmpMask = (PropertyMask) masks.get( i );			if ( propName.equalsIgnoreCase( tmpMask.getName( ) ) )			{				mask = tmpMask;				break;			}		}		PropertyCommand cmd = new PropertyCommand( module, getElement( ) );		if ( maskValue == null && mask != null )		{			// maskValue is null, remove the item from the structure list.			cmd.removeItem( new CachedMemberRef( maskProp ), masks					.indexOf( mask ) );		}		else		{			StructPropertyDefn maskDefn = (StructPropertyDefn) maskProp					.getStructDefn( ).getMember( PropertyMask.MASK_MEMBER );			StructPropertyDefn nameDefn = (StructPropertyDefn) maskProp					.getStructDefn( ).getMember( PropertyMask.NAME_MEMBER );			String value = maskDefn.validateValue( getModule( ), maskValue )					.toString( );			/*			 * If the property has no mask related to, adds a new mask item into			 * the structure list.			 */			if ( mask == null )			{				mask = new PropertyMask( );				mask.setProperty( maskDefn, value );				mask.setProperty( nameDefn, propName );				cmd.addItem( new CachedMemberRef( maskProp ), mask );			}			else			{				// changes the mask value.				MemberRef memberRef = new CachedMemberRef( maskProp, masks						.indexOf( mask ), PropertyMask.MASK_MEMBER );				cmd.setMember( memberRef, value );			}		}	}