gedi-geode-extensions-core/src/main/java/gedi/solutions/geode/lucene/TextPolicySearchStrategy.java
public <K, V> Collection<String>  saveSearchResultsWithPageKeys(TextPageCriteria criteria,String query, Predicate<LuceneResultStruct<K, V>> filter, Region<String,Collection<K>> pageKeysRegion)
		{
			if(criteria == null)
				return null;
			
			if(criteria.getId() == null || criteria.getId().length() == 0)
				throw new IllegalArgumentException("Default criteria's id is required");
					
			try
			{	
				//clearing asynchronously
				GeodePagination pagination = new GeodePagination();
				
				pagination.clearSearchResultsByPage(criteria, pageKeysRegion);
				
				 List<Map.Entry<K, V>> results = executeQuery(criteria, query, filter);
				
				 List<String> keys = pagination.storePaginationMap(criteria.getId(),criteria.getEndIndex() -criteria.getBeginIndex() ,pageKeysRegion,
						 results);
				 
				 return keys;
			
			}
			catch (LuceneQueryException e)
			{
				throw new FunctionException(e);
			}		
		}
public <K, V> Collection<String>  saveSearchResultsWithPageKeys(TextPageCriteria criteria,String query, Predicate<LuceneResultStruct<K, V>> filter, Region<String,Collection<K>> pageKeysRegion)
		{
			if(criteria == null)
				return null;
			
			if(criteria.getId() == null || criteria.getId().length() == 0)
				throw new IllegalArgumentException("Default criteria's id is required");
					
			try
			{	
				//clearing asynchronously
				GeodePagination pagination = new GeodePagination();
				
				pagination.clearSearchResultsByPage(criteria, pageKeysRegion);
				
				 List<Map.Entry<K, V>> results = executeQuery(criteria, query, filter);
				
				 List<String> keys = pagination.storePaginationMap(criteria.getId(),criteria.getEndIndex() -criteria.getBeginIndex() ,pageKeysRegion,
						 results);
				 
				 return keys;
			
			}
			catch (LuceneQueryException e)
			{
				throw new FunctionException(e);
			}		
		}
------------------------------------------------