Package org.dspace.utils

Examples of org.dspace.utils.DSpace


            String resourceIdentifier = requestUri.substring(requestUri.indexOf(RESOURCE) + RESOURCE.length() + 1);
            resourceIdentifier = resourceIdentifier.substring(0, resourceIdentifier.indexOf(DRI) - 1);

            Context context = ContextUtil.obtainContext(request);

            IdentifierService dis = new DSpace().getSingletonService(IdentifierService.class);

            DSpaceObject dso = dis.resolve(context, resourceIdentifier);

            if (dso == null) return null;
View Full Code Here


    }


    private DSpaceObject getDSO(HttpServletRequest request, String resourceIdentifier) {
        DSpaceObject dso=null;
        IdentifierService identifierService = new DSpace().getSingletonService(IdentifierService.class);
        Context context =null;
        try {
            context = new Context();
            context.turnOffAuthorisationSystem();
            dso = identifierService.resolve(context, resourceIdentifier);
View Full Code Here

        if(resourceID==null || "".equals(resourceID)) return STATUS_FORBIDDEN;

        // try to resolve DOI
        DSpaceObject dso=null;
        IdentifierService identifierService = new DSpace().getSingletonService(IdentifierService.class);
        Context context =null;
        try {
            context = new Context();
            context.turnOffAuthorisationSystem();
            dso = identifierService.resolve(context, resourceID);
View Full Code Here

            return;
        }

        if ((user_ip == null) || (user_ip.length() == 0))
        {
            new DSpace().getEventService().fireEvent(new UsageEvent(action, request, context, dspaceObject));
        }
        else
        {
            new DSpace().getEventService().fireEvent(
                    new UsageEvent(action, user_ip, user_agent, xforwarderfor, context, dspaceObject));
        }

        log.debug("fired event");
    }
View Full Code Here

        }


    }
     private static UserSelectionActionConfig createUserAssignmentActionConfig(String userSelectionActionID) {
        return new DSpace().getServiceManager().getServiceByName(userSelectionActionID, UserSelectionActionConfig.class);
    }
View Full Code Here

     private static UserSelectionActionConfig createUserAssignmentActionConfig(String userSelectionActionID) {
        return new DSpace().getServiceManager().getServiceByName(userSelectionActionID, UserSelectionActionConfig.class);
    }

    public static WorkflowActionConfig createWorkflowActionConfig(String actionID){
        return new DSpace().getServiceManager().getServiceByName(actionID, WorkflowActionConfig.class);
    }
View Full Code Here

                }
            }
           
            // Log that the bitstream has been viewed, this is non-cached and the complexity
            // of adding it to the sitemap for every possible bitstream uri is not very tractable
            new DSpace().getEventService().fireEvent(
                                new UsageEvent(
                                                UsageEvent.Action.VIEW,
                                                ObjectModelHelper.getRequest(objectModel),
                                                ContextUtil.obtainContext(ObjectModelHelper.getRequest(objectModel)),
                                                bitstream));
View Full Code Here

        if((event instanceof UsageEvent))
        {
            log.debug("Usage event received " + event.getName());

            // This is a wee bit messy but these keys should be combined in future.
            analyticsKey = new DSpace().getConfigurationService().getProperty("jspui.google.analytics.key");
            if (analyticsKey == null ) {
                analyticsKey = new DSpace().getConfigurationService().getProperty("xmlui.google.analytics.key");
            }

            if (analyticsKey != null ) {
                try {
                    UsageEvent ue = (UsageEvent)event;
View Full Code Here

    private static Logger log = Logger.getLogger(GoogleAccount.class);


    private GoogleAccount() {
        applicationName = new DSpace().getConfigurationService().getProperty("google-analytics.application.name");
        tableId = new DSpace().getConfigurationService().getProperty("google-analytics.table.id");
        emailAddress = new DSpace().getConfigurationService().getProperty("google-analytics.account.email");
        certificateLocation = new DSpace().getConfigurationService().getProperty("google-analytics.certificate.location");

        jsonFactory = JacksonFactory.getDefaultInstance();

        try {
            httpTransport = GoogleNetHttpTransport.newTrustedTransport();
View Full Code Here

     */
    protected Set<String> processed;

    public RDFizer() throws SQLException
    {
        this.configurationService = new DSpace().getConfigurationService();
        this.stdout = false;
        this.verbose = false;
        this.dryrun = false;
        this.lang = "TURTLE";
        this.processed = new CopyOnWriteArraySet<String>();
View Full Code Here

TOP

Related Classes of org.dspace.utils.DSpace

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.