package performa.search;

import oneit.objstore.BaseBusinessClass;
import oneit.objstore.rdbms.filters.EqualsFilter;
import performa.orm.JobApplication;


public class SearchApplicant extends BaseSearchApplicant
{
    private static final long serialVersionUID = 0L;
    
    // This constructor should not be called
    public SearchApplicant ()
    {
        // Do not add any code to this, always put it in initialiseNewObject
    }
    
    @Override
    public BaseBusinessClass[] doSearch() 
    {
        return JobApplication.SearchByDetails()
                                .byName(getDetails())
                                .andJob(new EqualsFilter<>(getJob()))
                                .search(getTransaction());
    }
}