Examples of TangoDAOFactory


Examples of fr.soleil.comete.dao.tangodao.TangoDAOFactory

        }

        double position = 0;
        TangoKey positionKey = generateWriteAttributeKey(this.deviceBundle
                .getString("UserMotorBean.attribut.position"));
        TangoDAOFactory factory = new TangoDAOFactory();
        AbstractDAO<Number> positionDAO = factory.createNumberDAO(positionKey);
        if (positionDAO != null && positionDAO.getData() != null) {
            position = positionDAO.getData().doubleValue();
            position -= this.increment;
            positionDAO.setData(position);
        }
View Full Code Here

Examples of fr.soleil.comete.dao.tangodao.TangoDAOFactory

            double position = 0;
            TangoKey attrKey = generateAttributeKey(this.deviceBundle
                    .getString("UserMotorBean.attribut.position"));

            TangoDAOFactory DAOFactory = new TangoDAOFactory();
            AbstractDAO<Number> attrDAO = DAOFactory.createNumberDAO(attrKey);

            if (attrDAO != null && attrDAO.getData() != null) {
                position = attrDAO.getData().doubleValue();
            }

            double distance = Math.abs(this.targetValue - position);
            if (distance > 0.00001) {
                if (this.increment == 0) {
                    position = this.targetValue;
                }
                else if (this.targetValue != position) {
                    if (distance > this.increment) {
                        position += this.increment * Math.signum(this.targetValue - position);
                    }
                    else {
                        position = this.targetValue;
                    }
                }
            }

            this.attr.insert(position);

        }
        else {

            double position = 0;
            TangoKey positionKey = generateAttributeKey(this.deviceBundle
                    .getString("UserMotorBean.attribut.position"));

            TangoDAOFactory daoFactory = new TangoDAOFactory();
            AbstractDAO<Number> positionDAO = daoFactory.createNumberDAO(positionKey);

            if (positionDAO != null && positionDAO.getData() != null) {

                position = positionDAO.getData().doubleValue();
                position += this.increment;
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.