Don't inject HandleService, use its provided Factory

This commit is contained in:
Tim Donohue
2015-10-07 16:28:12 -05:00
parent 51bef940c9
commit 05fbfeac7a

View File

@@ -10,6 +10,7 @@ package org.dspace.xoai.services.impl;
import java.sql.SQLException;
import javax.inject.Inject;
import org.dspace.content.DSpaceObject;
import org.dspace.handle.factory.HandleServiceFactory;
import org.dspace.handle.service.HandleService;
import org.dspace.xoai.services.api.context.ContextService;
import org.dspace.xoai.services.api.context.ContextServiceException;
@@ -20,8 +21,12 @@ public class DSpaceHandleResolver implements HandleResolver {
@Inject
private ContextService contextService;
@Inject
private HandleService handleService;
private final HandleService handleService;
public DSpaceHandleResolver()
{
handleService = HandleServiceFactory.getInstance().getHandleService();
}
@Override
public DSpaceObject resolve(String handle) throws HandleResolverException {