Package fr.xlim.ssd.capmanipulator.library

Examples of fr.xlim.ssd.capmanipulator.library.AppletComponent


public class AppletComponentRead extends ComponentRead {

    @Override
    public Component load(CapInputStream in) throws UnableToReadCapFileException {

        AppletComponent appletComponent = new AppletComponent();

        // we first read tag and size
        super.load((byte) ComponentEnum.APPLET_COMPONENT.getValue(), in, appletComponent);

        // we reset the count of byte read to zero
        in.resetCount();

        // count reading
        appletComponent.setCount(in.readByte());

        appletComponent.setApplets(new LinkedList<CapApplet>());

        for (int i = 0; i < appletComponent.getCount(); i++) {
            CapApplet ap = new CapAppletRead().load(in);
            appletComponent.getApplets().add(ap);
        }

        checkSize(in, appletComponent);

        return appletComponent;
View Full Code Here


                break;


            case APPLET_COMPONENT:
                logger.debug(LogType.COMPONENT.getMarker(), "Found Applet Component");
                AppletComponent ap = (AppletComponent) new AppletComponentRead().load(inputStream);
                capFile.getComponents().add(ap);
                // we add the offset to the method componentTab
                // contained in the applet componentTab
                for (CapApplet a : ap.getApplets()) {
                    Converter.addShortToArray(lOffset, a.getInstallMethodOffset());
                }
                break;

View Full Code Here

TOP

Related Classes of fr.xlim.ssd.capmanipulator.library.AppletComponent

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.