In order to use your new QueryFunction, you must deploy it to the Discovery Framework.
If you are using the default portal bundle, theyour-query-filter-name-filter|config directory that you created contains an ant build file. The ant deploy task places a .jar file containing the custom QueryFunction into the endeca-portal/tomcat-<version>/lib/ext directory.
Once you have deployed your custom QueryFunction, you can use it in any component.