Package fr.esrf.TangoApi

Examples of fr.esrf.TangoApi.DeviceData.extractStringArray()


        String[] result = null;
        DeviceProxy proxy = TangoDeviceHelper.getDeviceProxy(getModel());
        if (proxy != null) {
            try {
                DeviceData deviceData = proxy.command_inout(GET_CONFIG_LIST_CMD);
                result = deviceData.extractStringArray();
            } catch (DevFailed exception) {
                StringBuilder errorMessage = new StringBuilder();
                errorMessage.append("Error when executing command " + getModel() + "/" + GET_CONFIG_LIST_CMD + "/n");
                errorMessage.append(DevFailedUtils.toString(exception) + "/n");
                new Exception(errorMessage.toString()).printStackTrace();
View Full Code Here


        try {
            DeviceProxy proxy = new DeviceProxy(getModel());
            DeviceData argin = new DeviceData();
            argin.insert(arg);
            DeviceData cmdResult = proxy.command_inout(GET_PATH_SYMBOLS_CMD, argin);
            result = cmdResult.extractStringArray();
        } catch (DevFailed devFailed) {
            StringBuilder errorMessage = new StringBuilder();
            errorMessage.append("Error when executing command " + getModel() + "/" + GET_PATH_SYMBOLS_CMD + "/n");
            errorMessage.append(DevFailedUtils.toString(devFailed) + "/n");
            new Exception(errorMessage.toString()).printStackTrace();
View Full Code Here

            System.out.println("MONITORED - go for new fashion monitored attributes");
            DeviceProxy deviceProxy = TangoDeviceHelper.getDeviceProxy(archivingDevicePath);
            if (deviceProxy != null) {
                try {
                    DeviceData argout = deviceProxy.command_inout("GetCurrentArchivedAtt");
                    String[] archivedAttributesList = argout.extractStringArray();
                    if (archivedAttributesList != null) {
                        for (String attribute : archivedAttributesList) {
                            System.out.println("\t" + attribute);
                            attributesList.add(attribute);
                        }
View Full Code Here

                        if (TangoCommandHelper.isCommandExist(dataRecorderDeviceName,
                                "GetConfigList")) {
                            DeviceData deviceData = dataRecorderProxy
                                    .command_inout("GetConfigList");
                            if (deviceData != null) {
                                configList = deviceData.extractStringArray();
                            }
                        }
                    }
                }
                catch (DevFailed e) {
View Full Code Here

            DeviceData argout = proxy.command_inout("ShowCurrentPositions");
            if (argout != null) {
                // --------------------------------------------------------------------
                // Grab every sample configuration into an Array
                String[] samplesConfigurations = argout.extractStringArray();

                // For each configuration, let's decode the Sample
                for (int i = 0; i < samplesConfigurations.length; i++) {
                    String sampleConfiguration = samplesConfigurations[i];
View Full Code Here

                result = proxy.command_inout(commandName);
            } catch (DevFailed e) {
                throw new SourceDeviceException(DevFailedUtils.toString(e));
            }
            String[] sourceArray = result.extractStringArray();
            sourceList = Arrays.asList(sourceArray);
        }

        return sourceList;
    }
View Full Code Here

        String[] result = null;
        DeviceProxy proxy = TangoDeviceHelper.getDeviceProxy(modelForListConfig);
        if (proxy != null) {
            try {
                DeviceData deviceData = proxy.command_inout(DataRecorderModel.GET_CONFIG_LIST_CMD);
                result = deviceData.extractStringArray();
            }
            catch (DevFailed exception) {
                DataRecorderMessageManager.notifyExecuteCommandErrorDetected(modelForListConfig, DataRecorderModel.GET_CONFIG_LIST_CMD, exception);
            }
        }
View Full Code Here

            try {
                DeviceData devDataIn = new DeviceData();
                devDataIn.insert(scriptName);
                DeviceData devDataOut = proxy.command_inout(DataRecorderModel.GET_SCRIPTS_INFO_CMD, devDataIn);
                if (devDataOut != null) {
                    result = devDataOut.extractStringArray();
                }
            } catch (DevFailed e) {
                DataRecorderMessageManager.notifyExecuteCommandErrorDetected(model, DataRecorderModel.GET_SCRIPTS_INFO_CMD, e);

                result = null;
View Full Code Here

                result = proxy.command_inout(commandName);
            } catch (DevFailed e) {
                throw new SourceDeviceException(DevFailedUtils.toString(e));
            }
            String[] sourceArray = result.extractStringArray();
            sourceList = Arrays.asList(sourceArray);
        }

        return sourceList;
    }
View Full Code Here

                postRecordingCommand = data.extractString();
                setPostRecordingValues();

                executedCommand = GET_DATA_MODEL_CMD;
                data = proxy.command_inout(GET_DATA_MODEL_CMD);
                datamodels = data.extractStringArray();

                executedCommand = SCRIPTS_ATTR;
                DeviceAttribute deviceAttribute = proxy.read_attribute(SCRIPTS_ATTR);
                tabScripts = deviceAttribute.extractStringArray();
            } catch (DevFailed exception) {
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.