All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.jpedal.examples.viewer.objects.FXClientExternalHandler Maven / Gradle / Ivy

There is a newer version: 7.15.25
Show newest version
/*
 * ===========================================
 * Java Pdf Extraction Decoding Access Library
 * ===========================================
 *
 * Project Info:  http://www.idrsolutions.com
 * Help section for developers at http://www.idrsolutions.com/support/
 *
 * (C) Copyright 1997-2017 IDRsolutions and Contributors.
 *
 * This file is part of JPedal/JPDF2HTML5
 *
 @LICENSE@
 *
 * ---------------
 * FXClientExternalHandler.java
 * ---------------
 */
package org.jpedal.examples.viewer.objects;

import org.jpedal.examples.viewer.gui.FXAdditionalData;
import org.jpedal.external.Options;

/**
 * Additional handlers used in Client
 *
 * @author markee
 */
public class FXClientExternalHandler extends ClientExternalHandler {

    /**
     * Used in JavaFX to display additional objects if decoding with transition
     */
    private FXAdditionalData additionaValuesforPage;

    @Override
    public void addExternalHandler(final Object newHandler, final int type) {

        switch (type) {

            case Options.JavaFX_ADDITIONAL_OBJECTS:
                additionaValuesforPage = (FXAdditionalData) newHandler;
                break;

            default:
                super.addExternalHandler(newHandler, type);

        }
    }

    @Override
    public Object getExternalHandler(final int type) {

        switch (type) {

            case Options.JavaFX_ADDITIONAL_OBJECTS:
                return additionaValuesforPage;

            default:
                return super.getExternalHandler(type);

        }
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy