container/profiles/src/main/java/org/mobicents/slee/container/profile/ProfileTableImpl.java
public Collection<ProfileLocalObject> findProfilesByAttribute(String attributeName,
			Object attributeValue) throws NullPointerException,
			IllegalArgumentException, TransactionRequiredLocalException,
			SLEEException {
		
		if (logger.isDebugEnabled()) {
			logger.debug("findProfilesByAttribute( attributeName = "+attributeName+" , attributeValue = "+attributeValue+" )");
		}
		
		sleeContainer.getTransactionManager().mandateTransaction();

		// We get profile entities
		Collection<ProfileEntity> profileEntities = null;
		try {
			profileEntities = getProfileEntitiesByAttribute(attributeName, attributeValue, true);
		}
		catch (AttributeNotIndexedException e) {
			throw new SLEEException(e.getMessage(),e);
		} catch (UnrecognizedAttributeException e) {
			throw new IllegalArgumentException(e);
		} catch (AttributeTypeMismatchException e) {
			throw new IllegalArgumentException(e);
		}

		// We need ProfileLocalObjects
       ArrayList<ProfileLocalObject> plocs = new ArrayList<ProfileLocalObject>();
       for(ProfileEntity profileEntity : profileEntities) {
    	   plocs.add(transactionView.getProfile(profileEntity).getProfileLocalObject());
      }
      return Collections.unmodifiableCollection(plocs);
	}
public Collection<ProfileLocalObject> findProfilesByAttribute(String attributeName,
			Object attributeValue) throws NullPointerException,
			IllegalArgumentException, TransactionRequiredLocalException,
			SLEEException {
		
		if (logger.isDebugEnabled()) {
			logger.debug("findProfilesByAttribute( attributeName = "+attributeName+" , attributeValue = "+attributeValue+" )");
		}
		
		sleeContainer.getTransactionManager().mandateTransaction();

		// We get profile entities
		Collection<ProfileEntity> profileEntities = null;
		try {
			profileEntities = getProfileEntitiesByAttribute(attributeName, attributeValue, true);
		}
		catch (AttributeNotIndexedException e) {
			throw new SLEEException(e.getMessage(),e);
		} catch (UnrecognizedAttributeException e) {
			throw new IllegalArgumentException(e);
		} catch (AttributeTypeMismatchException e) {
			throw new IllegalArgumentException(e);
		}

		// We need ProfileLocalObjects
       ArrayList<ProfileLocalObject> plocs = new ArrayList<ProfileLocalObject>();
       for(ProfileEntity profileEntity : profileEntities) {
    	   plocs.add(transactionView.getProfile(profileEntity).getProfileLocalObject());
      }
      return Collections.unmodifiableCollection(plocs);
	}
public Collection < ProfileLocalObject > findProfilesByAttribute ( String attributeName , Object attributeValue ) throws NullPointerException , IllegalArgumentException , TransactionRequiredLocalException , SLEEException { if ( logger . isDebugEnabled ( ) ) { logger . debug ( "findProfilesByAttribute( attributeName = " + attributeName + " , attributeValue = " + attributeValue + " )" ) ; } sleeContainer . getTransactionManager ( ) . mandateTransaction ( ) ; // We get profile entities Collection < ProfileEntity > profileEntities = null ; try { profileEntities = getProfileEntitiesByAttribute ( attributeName , attributeValue , true ) ; } catch ( AttributeNotIndexedException e ) { throw new SLEEException ( e . getMessage ( ) , e ) ; } catch ( UnrecognizedAttributeException e ) { throw new IllegalArgumentException ( e ) ; } catch ( AttributeTypeMismatchException e ) { throw new IllegalArgumentException ( e ) ; } // We need ProfileLocalObjects ArrayList < ProfileLocalObject > plocs = new ArrayList < ProfileLocalObject > ( ) ; for ( ProfileEntity profileEntity : profileEntities ) { plocs . add ( transactionView . getProfile ( profileEntity ) . getProfileLocalObject ( ) ) ; } return Collections . unmodifiableCollection ( plocs ) ; }
/*
(non-Javadoc)
@see javax.slee.profile.ProfileTable#findProfilesByAttribute(java.lang.String, java.lang.Object)
/ * ( non - Javadoc )