Examples of DbDatum


Examples of fr.esrf.TangoApi.DbDatum

            // //storage/recorder/datarecorder.1/
            String dataRecorderDeviceName = "storage/recorder/datarecorder.1";
            Database database = TangoDeviceHelper.getDatabase();
            if ((database != null) && (scanServer != null) && !scanServer.isEmpty()) {
                try {
                    DbDatum dbDatum = database.get_device_property(scanServer, "DataRecorder");
                    if (dbDatum != null) {
                        dataRecorderDeviceName = dbDatum.extractString();
                    }

                    if ((dataRecorderDeviceName != null) && !dataRecorderDeviceName.isEmpty()) {
                        DeviceProxy dataRecorderProxy = TangoDeviceHelper.getDeviceProxy(dataRecorderDeviceName);
                        if (TangoCommandHelper.isCommandExist(dataRecorderDeviceName, "GetConfigList")) {
View Full Code Here

Examples of fr.esrf.TangoApi.DbDatum

            return suggestions;
        }
        if (m_database != null) {
            // get ActuatorsFile property
            try {
                DbDatum m_dataActuators = m_database.get_device_property(scanServerName,
                        "ActuatorsFile");
                String[] actuatorsFile = m_dataActuators.extractStringArray();
                if (actuatorsFile != null && actuatorsFile.length > 0) {
                    suggestions.setActuatorSuggestionList(parseSuggestions(scanServerName,
                            "ActuatorsFile", actuatorsFile));
                }
            }
            catch (DevFailed e) {
            }

            // get SensorsFile property
            try {
                DbDatum m_dataSensors = m_database.get_device_property(scanServerName,
                        "SensorsFile");
                String[] sensorsFile = m_dataSensors.extractStringArray();
                if (sensorsFile != null && sensorsFile.length > 0) {
                    suggestions.setSensorSuggestionList(parseSuggestions(scanServerName,
                            "SensorsFile", sensorsFile));
                }
            }
            catch (DevFailed e) {
            }

            // get TimebasesFile property
            try {
                DbDatum m_dataTimebases = m_database.get_device_property(scanServerName,
                        "TimebasesFile");
                String[] timebasesFile = m_dataTimebases.extractStringArray();
                if (timebasesFile != null && timebasesFile.length > 0) {
                    suggestions.setTimebaseSuggestionList(parseSuggestions(scanServerName,
                            "TimebasesFile", timebasesFile));
                }
            }
View Full Code Here

Examples of fr.esrf.TangoApi.DbDatum

            // //storage/recorder/datarecorder.1/
            String dataRecorderDeviceName = "storage/recorder/datarecorder.1";
            Database database = TangoDeviceHelper.getDatabase();
            if (database != null) {
                try {
                    DbDatum dbDatum = database.get_device_property(scanServer, "DataRecorder");
                    if (dbDatum != null) {
                        dataRecorderDeviceName = dbDatum.extractString();
                    }

                    if (dataRecorderDeviceName != null && !dataRecorderDeviceName.isEmpty()) {
                        DeviceProxy dataRecorderProxy = TangoDeviceHelper.getDeviceProxy(dataRecorderDeviceName);
                        if (TangoCommandHelper.isCommandExist(dataRecorderDeviceName, "GetConfigList")) {
View Full Code Here

Examples of fr.esrf.TangoApi.DbDatum

    String dataRecorderPath = pnl.getDataRecorderPath();
    DeviceProxy deviceProxy = TangoDeviceHelper
        .getDeviceProxy(dataRecorderPath);
    try {
      DbDatum property = deviceProxy.get_property(ARCHIVING_DEVICE_PROP);
      archivingDeviceName = property.extractString();
    } catch (DevFailed e) {
      TechnicalDataMessageManager.notifyReadAttributeErrorDetected(
          dataRecorderPath, ARCHIVING_DEVICE_PROP, e);
    }
    // archivingDeviceName can be null
View Full Code Here

Examples of fr.esrf.TangoApi.DbDatum

        String tempTechModel = null;
        String property = "";
        try {
            Database database = TangoDeviceHelper.getDatabase();
            property = AUTH_DEVICE;
            DbDatum dbDatum = database.get_device_property(getModel(), property);
            tempAuthModel = dbDatum.extractString();

            property = TECH_DEVICE;
            dbDatum = database.get_device_property(getModel(), property);
            tempTechModel = dbDatum.extractString();

            if ((tempAuthModel != null) && (!tempAuthModel.trim().isEmpty())
                    && (!ObjectUtils.sameObject(getAuthModel(), tempAuthModel))) {
                authModel = tempAuthModel;
            }
View Full Code Here

Examples of fr.esrf.TangoApi.DbDatum

        m_strTechnicalDataPath = pnl.getPathTechnicalData();

        String dataRecorderPath = pnl.getDataRecorderPath();
        DeviceProxy deviceProxy = TangoDeviceHelper.getDeviceProxy(dataRecorderPath);
        try {
            DbDatum property = deviceProxy.get_property(ARCHIVING_DEVICE_PROP);
            archivingDeviceName = property.extractString();
        } catch (DevFailed e) {
            e.printStackTrace();
        }
        // archivingDeviceName can be null
        TangoDataBaseManager.getInstance().setArchivingDevicePath(archivingDeviceName);
View Full Code Here

Examples of fr.esrf.TangoApi.DbDatum

            // Read the property of DataRecorder = //storage/recorder/datarecorder.1/
            String dataRecorderDeviceName = "storage/recorder/datarecorder.1";
            Database database = TangoDeviceHelper.getDatabase();
            if (database != null) {
                try {
                    DbDatum dbDatum = database.get_device_property(scanServer, "DataRecorder");
                    if (dbDatum != null) {
                        dataRecorderDeviceName = dbDatum.extractString();
                    }

                    if (dataRecorderDeviceName != null && !dataRecorderDeviceName.isEmpty()) {
                        DeviceProxy dataRecorderProxy = TangoDeviceHelper
                                .getDeviceProxy(dataRecorderDeviceName);
View Full Code Here

Examples of fr.esrf.TangoApi.DbDatum

            return suggestions;
        }
        if (m_database != null) {
            // get ActuatorsFile property
            try {
                DbDatum m_dataActuators = m_database.get_device_property(scanServerName,
                        "ActuatorsFile");
                String[] actuatorsFile = m_dataActuators.extractStringArray();
                if (actuatorsFile != null && actuatorsFile.length > 0) {
                    suggestions.setActuatorSuggestionList(parseSuggestions(scanServerName,
                            "ActuatorsFile", actuatorsFile));
                }
            }
            catch (DevFailed e) {
                System.out.println(DevFailedUtils.toString(e));
            }

            // get SensorsFile property
            try {
                DbDatum m_dataSensors = m_database.get_device_property(scanServerName,
                        "SensorsFile");
                String[] sensorsFile = m_dataSensors.extractStringArray();
                if (sensorsFile != null && sensorsFile.length > 0) {
                    suggestions.setSensorSuggestionList(parseSuggestions(scanServerName,
                            "SensorsFile", sensorsFile));
                }
            }
            catch (DevFailed e) {
                System.out.println(DevFailedUtils.toString(e));
            }

            // get TimebasesFile property
            try {
                DbDatum m_dataTimebases = m_database.get_device_property(scanServerName,
                        "TimebasesFile");
                String[] timebasesFile = m_dataTimebases.extractStringArray();
                if (timebasesFile != null && timebasesFile.length > 0) {
                    suggestions.setTimebaseSuggestionList(parseSuggestions(scanServerName,
                            "TimebasesFile", timebasesFile));
                }
            }
View Full Code Here

Examples of fr.esrf.TangoApi.DbDatum

    }

    private DbDatum makeDbDatum(final String propname, final String value) {

        final String[] splitted = makeStringArray(value);
        DbDatum datum = null;

        if (splitted.length == 1) {
            datum = new DbDatum(propname, splitted[0]);
        }
        else {
            datum = new DbDatum(propname, splitted);
        }

        return datum;
    }
View Full Code Here

Examples of fr.esrf.TangoApi.DbDatum

    private void updateValue() {
        if (m_database == null) {
            return;
        }
        try {
            final DbDatum tmpDatum = makeDbDatum();
            m_database.put_device_property(deviceName, new DbDatum[] { tmpDatum });
        }
        catch (final Exception e) {
            e.printStackTrace();
        }
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.