sPFLib/src/main/java/it/polimi/spf/lib/search/SPFSearch.java
public void startSearch(final int tag,
			SPFSearchDescriptor searchDescriptor, final SearchCallback callback) {
		// replace equivalent query ( equivalent == same tag )
		if (mTagToId.get(tag) != null) {
			Log.d("start search", "mTagToId.get(tag) != null");
			String queryId = mTagToId.get(tag);
			Log.d("start search", "mTagToId.get(tag)= " + mTagToId.get(tag));
			mTagToId.delete(tag);
			SearchCallback state = mCallbacks.remove(queryId);
			if (queryId != null && state != null) {
				Log.d("start search", "queryId: " + queryId + ", state: " + state );
				mSearchInterface.stopSearch(queryId);
				Log.d("start search", "stopSearch");

			}
		}

		Log.d("start search", "startSearch");
		mSearchInterface.startSearch(searchDescriptor,
				new SPFSearchCallbackImpl(callback, tag));
	}
public void startSearch(final int tag,
			SPFSearchDescriptor searchDescriptor, final SearchCallback callback) {
		// replace equivalent query ( equivalent == same tag )
		if (mTagToId.get(tag) != null) {
			Log.d("start search", "mTagToId.get(tag) != null");
			String queryId = mTagToId.get(tag);
			Log.d("start search", "mTagToId.get(tag)= " + mTagToId.get(tag));
			mTagToId.delete(tag);
			SearchCallback state = mCallbacks.remove(queryId);
			if (queryId != null && state != null) {
				Log.d("start search", "queryId: " + queryId + ", state: " + state );
				mSearchInterface.stopSearch(queryId);
				Log.d("start search", "stopSearch");

			}
		}

		Log.d("start search", "startSearch");
		mSearchInterface.startSearch(searchDescriptor,
				new SPFSearchCallbackImpl(callback, tag));
	}
Starts a search for remote people. The application must provide a tag,
used to replace equivalent queries, a {@link SearchDescriptor} containing
the configuration of the search, and a {@link SearchCallback} to be
notified of found results.

@param tag
- the tag identifying this query
@param searchDescriptor
- the descriptor of the search
@param callback
- the callback to be notified of results.