Package eu.planets_project.pp.plato.evaluation

Examples of eu.planets_project.pp.plato.evaluation.MeasurementsDescriptor


    protected boolean loadMeasurementsDescription(String filename) {
        try {
            File descr = FileUtils.getResourceFile(filename);
            if (descr != null) {
                descriptorStr = new String(FileUtils.getBytesFromFile(descr), "UTF-8");
                descriptor= new MeasurementsDescriptor();
                descriptor.addMeasurementInfos(new StringReader(descriptorStr));
                return true;
            }
        } catch (Exception e) {
            log.error(e);
View Full Code Here


    public String saveRequirements() {
        PrepareChangesForPersist prep = new PrepareChangesForPersist(user.getUsername());

        // before persisting: adjust all scales of leaves
        List<Leaf> leaves = reqexpTree.getRoot().getAllLeaves();
        MeasurementsDescriptor  descriptor = MiniRED.getInstance().getMeasurementsDescriptor();
        for (Leaf l : leaves) {
            MeasurementInfoUri mInfo = l.getMeasurementInfo().toMeasurementInfoUri();
            if (mInfo.getAsURI() != null) {
                Scale s = descriptor.getMeasurementScale(mInfo);
                if (s != null) {
                    l.adjustScale(s);
                }
            }
        }
View Full Code Here

TOP

Related Classes of eu.planets_project.pp.plato.evaluation.MeasurementsDescriptor

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.