Package eu.scape_project.planning.manager

Examples of eu.scape_project.planning.manager.ByteStreamManager


        ByteStream contentByteStream = new ByteStream();
        contentByteStream.setData(content.getBytes());
        object.setData(contentByteStream);

        // mock ByteStreamManager
        ByteStreamManager byteStreamManager = mock(ByteStreamManager.class);
        when(byteStreamManager.store(null, content.getBytes())).thenReturn("myPid");

        // execute test
        DigitalObjectManager digitalObjectManager = new DigitalObjectManager();
        digitalObjectManager.setByteStreamManager(byteStreamManager);
        digitalObjectManager.moveDataToStorage(object);
View Full Code Here


        object.setFullname("test.txt");
        object.setContentType("text");
        object.getData().setData(content.getBytes());

        // mock ByteStreamManager
        ByteStreamManager byteStreamManager = mock(ByteStreamManager.class);
        when(byteStreamManager.load("pid")).thenReturn(content.getBytes());

        // execute test
        DigitalObjectManager digitalObjectManager = new DigitalObjectManager();
        digitalObjectManager.setByteStreamManager(byteStreamManager);
        DigitalObject resultObject = digitalObjectManager.getCopyOfDataFilledDigitalObject(object);
View Full Code Here

TOP

Related Classes of eu.scape_project.planning.manager.ByteStreamManager

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.