Search in sources :

Example 1 with MatchCallback

use of com.infiniteautomation.mango.regex.MatchCallback in project ma-modules-public by infiniteautomation.

the class SerialDataSourceRT method serialEvent.

@Override
public void serialEvent(SerialPortProxyEvent evt) {
    // Keep a lock on the buffer while we do this
    synchronized (this.buffer) {
        // If our port is dead, say so
        if (this.port == null) {
            raiseEvent(POINT_READ_EXCEPTION_EVENT, System.currentTimeMillis(), true, new TranslatableMessage("event.serial.readFailedPortNotSetup"));
            return;
        }
        // String msg = null;
        try {
            // Don't read during timeout events as there could be no data and this would block till there is
            if (!(evt instanceof TimeoutSerialEvent)) {
                InputStream in = this.port.getInputStream();
                int data;
                // this may not be the full message, or may read multiple messages
                while ((data = in.read()) > -1) {
                    if (buffer.size() >= this.vo.getMaxMessageSize()) {
                        buffer.popAll();
                        raiseEvent(POINT_READ_EXCEPTION_EVENT, System.currentTimeMillis(), true, new TranslatableMessage("event.serial.readFailed", "Max message size reached!"));
                        // Give up
                        return;
                    }
                    buffer.push(data);
                }
                // Log our buffer contents
                byte[] logMsg = buffer.peekAll();
                if (this.vo.isLogIO()) {
                    if (this.vo.isHex())
                        this.ioLog.log(true, logMsg);
                    else
                        this.ioLog.log("I: " + new String(logMsg, Common.UTF8_CS));
                }
                // Serial Event so setup a Timeout Task to fire after the message timeout
                if (this.buffer.size() > 0)
                    this.timeoutTask = new TimeoutTask(this.vo.getReadTimeout(), new SerialTimeoutClient(this));
            }
            // We either use a terminator and timeout OR just a Timeout
            if (vo.getUseTerminator()) {
                // If timeout then process the buffer
                // If serial event then read input and process buffer
                // "!([A-Z0-9]{3,3})([a-zA-Z])(.*);";
                String messageRegex = vo.getMessageRegex();
                // DS Information
                int pointIdentifierIndex = vo.getPointIdentifierIndex();
                // Create a String so we can use Regex and matching
                String msg = null;
                if (this.vo.isHex()) {
                    msg = convertFromHex(buffer.peekAll());
                } else {
                    msg = new String(buffer.peekAll(), Common.UTF8_CS);
                }
                // Now we have a string that contains the entire contents of the buffer,
                // split on terminator, keep it on the end of the message and process any full messages
                // and pop them from the buffer
                String[] messages = splitMessages(msg, this.vo.getMessageTerminator());
                for (String message : messages) {
                    // potentially be one incomplete message.
                    if (canProcessTerminatedMessage(message, this.vo.getMessageTerminator())) {
                        // Pop off this message
                        this.buffer.pop(message.length());
                        if (LOG.isDebugEnabled())
                            LOG.debug("Matching will use String: " + message);
                        final AtomicBoolean matcherFailed = new AtomicBoolean(false);
                        pointListChangeLock.readLock().lock();
                        try {
                            for (final DataPointRT dp : this.dataPoints) {
                                SerialPointLocatorVO plVo = dp.getVO().getPointLocator();
                                MatchCallback callback = new MatchCallback() {

                                    @Override
                                    public void onMatch(String pointIdentifier, PointValueTime value) {
                                        if (!updatePointValue(value, dp)) {
                                            matcherFailed.set(true);
                                            raiseEvent(POINT_READ_PATTERN_MISMATCH_EVENT, System.currentTimeMillis(), true, new TranslatableMessage("event.serial.invalidValue", dp.getVO().getXid()));
                                        }
                                    }

                                    @Override
                                    public void pointPatternMismatch(String message, String messageRegex) {
                                    // Ignore as this just isn't a message we care about
                                    }

                                    @Override
                                    public void messagePatternMismatch(String message, String messageRegex) {
                                        raiseEvent(POINT_READ_PATTERN_MISMATCH_EVENT, System.currentTimeMillis(), true, new TranslatableMessage("event.serial.patternMismatch", messageRegex, message));
                                        matcherFailed.set(true);
                                    }

                                    @Override
                                    public void pointNotIdentified(String message, String messageRegex, int pointIdentifierIndex) {
                                    // Don't Care
                                    }

                                    @Override
                                    public void matchGeneralFailure(Exception e) {
                                        raiseEvent(POINT_READ_EXCEPTION_EVENT, System.currentTimeMillis(), true, new TranslatableMessage("event.serial.readFailed", e.getMessage()));
                                        matcherFailed.set(true);
                                    }
                                };
                                try {
                                    matchPointValue(message, messageRegex, pointIdentifierIndex, plVo, vo.isHex(), LOG, callback);
                                } catch (Exception e) {
                                    callback.matchGeneralFailure(e);
                                }
                            }
                        } finally {
                            pointListChangeLock.readLock().unlock();
                        }
                        // If no failures...
                        if (!matcherFailed.get())
                            returnToNormal(POINT_READ_PATTERN_MISMATCH_EVENT, System.currentTimeMillis());
                        returnToNormal(POINT_READ_EXCEPTION_EVENT, System.currentTimeMillis());
                    }
                    if (evt instanceof TimeoutSerialEvent) {
                        // Clear the buffer
                        this.buffer.popAll();
                    } else {
                        // Check to see if we have remaining data, if not cancel timeout
                        if (this.buffer.size() == 0)
                            this.timeoutTask.cancel();
                    }
                }
                return;
            } else {
                // Do we have a timeout generated message?
                if (evt instanceof TimeoutSerialEvent) {
                    String msg = null;
                    // We are a timeout event so we have a timeout, pop everything into the message and assume its a message
                    if (this.vo.isHex()) {
                        msg = convertFromHex(buffer.popAll());
                    } else {
                        msg = new String(buffer.popAll(), Common.UTF8_CS);
                    }
                    // Just do a match on the Entire Message because we are not using Terminator
                    // String messageRegex = ".*"; //Match everything
                    // int pointIdentifierIndex = 0; //Whole message
                    // "!([A-Z0-9]{3,3})([a-zA-Z])(.*);";
                    String messageRegex = vo.getMessageRegex();
                    // DS Information
                    int pointIdentifierIndex = vo.getPointIdentifierIndex();
                    if (LOG.isDebugEnabled())
                        LOG.debug("Matching will use String: " + msg);
                    final AtomicBoolean matcherFailed = new AtomicBoolean(false);
                    synchronized (pointListChangeLock) {
                        for (final DataPointRT dp : this.dataPoints) {
                            SerialPointLocatorVO plVo = dp.getVO().getPointLocator();
                            MatchCallback callback = new MatchCallback() {

                                @Override
                                public void onMatch(String pointIdentifier, PointValueTime pvt) {
                                    if (!updatePointValue(pvt, dp)) {
                                        matcherFailed.set(true);
                                        raiseEvent(POINT_READ_PATTERN_MISMATCH_EVENT, System.currentTimeMillis(), true, new TranslatableMessage("event.serial.invalidValue", dp.getVO().getXid()));
                                    }
                                    // Ensure we clear out the buffer...
                                    buffer.popAll();
                                }

                                @Override
                                public void pointPatternMismatch(String message, String messageRegex) {
                                // Ignore as this just isn't a message we care about
                                }

                                @Override
                                public void messagePatternMismatch(String message, String messageRegex) {
                                    raiseEvent(POINT_READ_PATTERN_MISMATCH_EVENT, System.currentTimeMillis(), true, new TranslatableMessage("event.serial.patternMismatch", messageRegex, message));
                                    matcherFailed.set(true);
                                }

                                @Override
                                public void pointNotIdentified(String message, String messageRegex, int pointIdentifierIndex) {
                                // Don't Care
                                }

                                @Override
                                public void matchGeneralFailure(Exception e) {
                                    raiseEvent(POINT_READ_EXCEPTION_EVENT, System.currentTimeMillis(), true, new TranslatableMessage("event.serial.readFailed", e.getMessage()));
                                    matcherFailed.set(true);
                                }
                            };
                            try {
                                matchPointValue(msg, messageRegex, pointIdentifierIndex, plVo, vo.isHex(), LOG, callback);
                            } catch (Exception e) {
                                callback.matchGeneralFailure(e);
                            }
                        }
                    }
                    // If no failures...
                    if (!matcherFailed.get())
                        returnToNormal(POINT_READ_PATTERN_MISMATCH_EVENT, System.currentTimeMillis());
                    returnToNormal(POINT_READ_EXCEPTION_EVENT, System.currentTimeMillis());
                }
            }
        } catch (Exception e) {
            LOG.error(e.getMessage(), e);
            // Ensure we clear out the buffer...
            this.buffer.popAll();
            raiseEvent(POINT_READ_EXCEPTION_EVENT, System.currentTimeMillis(), true, new TranslatableMessage("event.serial.readFailed", e.getMessage()));
        }
    }
// End synch
}
Also used : InputStream(java.io.InputStream) MatchCallback(com.infiniteautomation.mango.regex.MatchCallback) ShouldNeverHappenException(com.serotonin.ShouldNeverHappenException) SerialPortException(com.infiniteautomation.mango.io.serial.SerialPortException) IOException(java.io.IOException) TimeoutTask(com.serotonin.m2m2.util.timeout.TimeoutTask) AtomicBoolean(java.util.concurrent.atomic.AtomicBoolean) DataPointRT(com.serotonin.m2m2.rt.dataImage.DataPointRT) PointValueTime(com.serotonin.m2m2.rt.dataImage.PointValueTime) SerialPointLocatorVO(com.infiniteautomation.serial.vo.SerialPointLocatorVO) TranslatableMessage(com.serotonin.m2m2.i18n.TranslatableMessage)

Example 2 with MatchCallback

use of com.infiniteautomation.mango.regex.MatchCallback in project ma-modules-public by infiniteautomation.

the class AsciiFileEditDwr method testString.

@DwrPermission(user = true)
public ProcessResult testString(int dsId, String raw) {
    final ProcessResult pr = new ProcessResult();
    // Message we will work with
    String msg;
    if (dsId == -1) {
        pr.addContextualMessage("testString", "dsEdit.file.test.needsSave");
        return pr;
    }
    msg = StringEscapeUtils.unescapeJava(raw);
    // Map to store the values vs the points they are for
    final List<Map<String, Object>> results = new ArrayList<Map<String, Object>>();
    pr.addData("results", results);
    DataPointDao dpd = DataPointDao.instance;
    List<DataPointVO> points = dpd.getDataPoints(dsId, null);
    for (final DataPointVO vo : points) {
        final Map<String, Object> result = new HashMap<String, Object>();
        MatchCallback callback = new MatchCallback() {

            @Override
            public void onMatch(String pointIdentifier, PointValueTime value) {
                result.put("success", "true");
                result.put("name", vo.getName());
                result.put("identifier", pointIdentifier);
                result.put("value", value != null ? value.toString() : "null");
            }

            @Override
            public void pointPatternMismatch(String message, String pointValueRegex) {
                result.put("success", "false");
                result.put("name", vo.getName());
                result.put("error", new TranslatableMessage("dsEdit.file.test.noPointRegexMatch").translate(Common.getTranslations()));
            }

            @Override
            public void messagePatternMismatch(String message, String messageRegex) {
            }

            @Override
            public void pointNotIdentified(String message, String messageRegex, int pointIdentifierIndex) {
                result.put("success", "false");
                result.put("name", vo.getName());
                result.put("error", new TranslatableMessage("dsEdit.file.test.noIdentifierFound").translate(Common.getTranslations()));
            }

            @Override
            public void matchGeneralFailure(Exception e) {
                result.put("success", "false");
                result.put("name", vo.getName());
                result.put("error", new TranslatableMessage("common.default", e.getMessage()).translate(Common.getTranslations()));
            }
        };
        AsciiFilePointLocatorVO locator = vo.getPointLocator();
        AsciiFileDataSourceRT.matchPointValueTime(msg, Pattern.compile(locator.getValueRegex()), locator.getPointIdentifier(), locator.getPointIdentifierIndex(), locator.getDataTypeId(), locator.getValueIndex(), locator.getHasTimestamp(), locator.getTimestampIndex(), locator.getTimestampFormat(), callback);
        if (result.size() > 0) {
            results.add(result);
        }
    }
    return pr;
}
Also used : DataPointVO(com.serotonin.m2m2.vo.DataPointVO) DataPointDao(com.serotonin.m2m2.db.dao.DataPointDao) HashMap(java.util.HashMap) ProcessResult(com.serotonin.m2m2.i18n.ProcessResult) ArrayList(java.util.ArrayList) MatchCallback(com.infiniteautomation.mango.regex.MatchCallback) AsciiFilePointLocatorVO(com.infiniteautomation.asciifile.vo.AsciiFilePointLocatorVO) IOException(java.io.IOException) PointValueTime(com.serotonin.m2m2.rt.dataImage.PointValueTime) TranslatableMessage(com.serotonin.m2m2.i18n.TranslatableMessage) HashMap(java.util.HashMap) Map(java.util.Map) DwrPermission(com.serotonin.m2m2.web.dwr.util.DwrPermission)

Example 3 with MatchCallback

use of com.infiniteautomation.mango.regex.MatchCallback in project ma-modules-public by infiniteautomation.

the class AsciiFileDataSourceRT method fileEvent.

private void fileEvent(List<DataPointRT> dataPoints) {
    // Should never happen
    if (this.file == null) {
        raiseEvent(POINT_READ_EXCEPTION_EVENT, System.currentTimeMillis(), true, new TranslatableMessage("file.event.readFailedFileNotSetup"));
        return;
    }
    if (restrictedPath) {
        raiseEvent(POINT_READ_EXCEPTION_EVENT, Common.timer.currentTimeMillis(), true, new TranslatableMessage("dsEdit.file.pathRestrictedBy", vo.getFilePath()));
        return;
    }
    // The file is modified or we've just started, so read it.
    try {
        BufferedReader reader = new BufferedReader(new FileReader(this.file));
        String msg;
        if (!dataPoints.isEmpty()) {
            // TODO optimize to be better than numLines*numPoints
            while ((msg = reader.readLine()) != null) {
                // Give all points the chance to find their data
                for (final DataPointRT dp : dataPoints) {
                    AsciiFilePointLocatorRT pl = dp.getPointLocator();
                    final AsciiFilePointLocatorVO plVo = pl.getVo();
                    MatchCallback callback = new MatchCallback() {

                        @Override
                        public void onMatch(String pointIdentifier, PointValueTime value) {
                            if (!plVo.getHasTimestamp())
                                dp.updatePointValue(value);
                            else
                                dp.savePointValueDirectToCache(value, null, true, true);
                        }

                        @Override
                        public void pointPatternMismatch(String message, String pointValueRegex) {
                        // N/A
                        }

                        @Override
                        public void messagePatternMismatch(String message, String messageRegex) {
                        // N/A
                        }

                        @Override
                        public void pointNotIdentified(String message, String messageRegex, int pointIdentifierIndex) {
                            raiseEvent(POINT_READ_EXCEPTION_EVENT, Common.timer.currentTimeMillis(), false, new TranslatableMessage("file.event.insufficientGroups", dp.getVO().getExtendedName()));
                        }

                        @Override
                        public void matchGeneralFailure(Exception e) {
                            if (e instanceof ParseException)
                                raiseEvent(POINT_READ_EXCEPTION_EVENT, Common.timer.currentTimeMillis(), true, new TranslatableMessage("file.event.dateParseFailed", e.getMessage()));
                            else if (e instanceof NumberFormatException) {
                                raiseEvent(POINT_READ_EXCEPTION_EVENT, Common.timer.currentTimeMillis(), true, new TranslatableMessage("file.event.notNumber", e.getMessage()));
                            } else
                                raiseEvent(POINT_READ_EXCEPTION_EVENT, Common.timer.currentTimeMillis(), true, new TranslatableMessage("file.event.readFailed", e.getMessage()));
                        }
                    };
                    matchPointValueTime(msg, pl.getValuePattern(), plVo.getPointIdentifier(), plVo.getPointIdentifierIndex(), plVo.getDataTypeId(), plVo.getValueIndex(), plVo.getHasTimestamp(), plVo.getTimestampIndex(), plVo.getTimestampFormat(), callback);
                }
            }
            reader.close();
            returnToNormal(POINT_READ_EXCEPTION_EVENT, Common.timer.currentTimeMillis());
        }
    } catch (FileNotFoundException e) {
        raiseEvent(POINT_READ_EXCEPTION_EVENT, Common.timer.currentTimeMillis(), true, new TranslatableMessage("file.event.fileNotFound", e.getMessage()));
    } catch (IOException e) {
        raiseEvent(POINT_READ_EXCEPTION_EVENT, Common.timer.currentTimeMillis(), true, new TranslatableMessage("file.event.readFailed", e.getMessage()));
    } catch (NumberFormatException e) {
        raiseEvent(POINT_READ_EXCEPTION_EVENT, Common.timer.currentTimeMillis(), true, new TranslatableMessage("file.event.notNumber", e.getMessage()));
    }
}
Also used : FileNotFoundException(java.io.FileNotFoundException) MatchCallback(com.infiniteautomation.mango.regex.MatchCallback) IOException(java.io.IOException) AsciiFilePointLocatorVO(com.infiniteautomation.asciifile.vo.AsciiFilePointLocatorVO) ShouldNeverHappenException(com.serotonin.ShouldNeverHappenException) ParseException(java.text.ParseException) IOException(java.io.IOException) FileNotFoundException(java.io.FileNotFoundException) DataPointRT(com.serotonin.m2m2.rt.dataImage.DataPointRT) BufferedReader(java.io.BufferedReader) PointValueTime(com.serotonin.m2m2.rt.dataImage.PointValueTime) FileReader(java.io.FileReader) TranslatableMessage(com.serotonin.m2m2.i18n.TranslatableMessage) ParseException(java.text.ParseException)

Example 4 with MatchCallback

use of com.infiniteautomation.mango.regex.MatchCallback in project ma-modules-public by infiniteautomation.

the class SerialEditDwr method testString.

@DwrPermission(user = true)
public ProcessResult testString(String raw, int dsId, String messageRegex, String messageTerminator, int pointIdentifierIndex, boolean isHex, boolean useTerminator) {
    final ProcessResult pr = new ProcessResult();
    // Message we will work with
    String msg;
    if (dsId == -1) {
        pr.addContextualMessage("testString", "serial.test.needsSave");
        return pr;
    }
    msg = StringEscapeUtils.unescapeJava(raw);
    messageRegex = StringEscapeUtils.unescapeJava(messageRegex);
    messageTerminator = StringEscapeUtils.unescapeJava(messageTerminator);
    // Are we a hex string
    if (isHex) {
        if (!msg.matches("[0-9A-Fa-f]+")) {
            pr.addContextualMessage("testString", "serial.validate.notHex");
            return pr;
        }
    }
    // Map to store the values vs the points they are for
    final List<Map<String, String>> results = new ArrayList<Map<String, String>>();
    pr.addData("results", results);
    DataPointDao dpd = DataPointDao.instance;
    List<DataPointVO> points = dpd.getDataPoints(dsId, null);
    if (useTerminator) {
        // Convert the message
        String[] messages = SerialDataSourceRT.splitMessages(msg, messageTerminator);
        for (String message : messages) {
            if (SerialDataSourceRT.canProcessTerminatedMessage(message, messageTerminator)) {
                if (LOG.isDebugEnabled())
                    LOG.debug("Matching will use String: " + message);
                // Check all the points
                for (final DataPointVO vo : points) {
                    final Map<String, String> result = new HashMap<String, String>();
                    MatchCallback callback = new MatchCallback() {

                        @Override
                        public void onMatch(String pointIdentifier, PointValueTime pvt) {
                            result.put("name", vo.getName());
                            result.put("value", pvt.toString());
                            result.put("identifier", pointIdentifier);
                            result.put("success", "true");
                        }

                        @Override
                        public void pointPatternMismatch(String message, String messageRegex) {
                            result.put("success", "false");
                            result.put("name", vo.getName());
                            result.put("error", new TranslatableMessage("serial.test.noPointRegexMatch").translate(Common.getTranslations()));
                        }

                        @Override
                        public void messagePatternMismatch(String message, String messageRegex) {
                            result.put("success", "false");
                            result.put("name", vo.getName());
                            result.put("error", new TranslatableMessage("serial.test.noMessageMatch").translate(Common.getTranslations()));
                        }

                        @Override
                        public void pointNotIdentified(String message, String messageRegex, int pointIdentifierIndex) {
                            result.put("success", "false");
                            result.put("name", vo.getName());
                            result.put("error", new TranslatableMessage("serial.test.noIdentifierFound").translate(Common.getTranslations()));
                        }

                        /* (non-Javadoc)
							 * @see com.infiniteautomation.mango.regex.MatchCallback#matchGeneralFailure(java.lang.Exception)
							 */
                        @Override
                        public void matchGeneralFailure(Exception e) {
                            result.put("success", "false");
                            result.put("name", vo.getName());
                            result.put("error", new TranslatableMessage("common.default", e.getMessage()).translate(Common.getTranslations()));
                        }
                    };
                    try {
                        SerialDataSourceRT.matchPointValue(message, messageRegex, pointIdentifierIndex, (SerialPointLocatorVO) vo.getPointLocator(), isHex, LOG, callback);
                    } catch (Exception e) {
                        callback.matchGeneralFailure(e);
                    }
                    if (result.size() > 0) {
                        result.put("message", message);
                        results.add(result);
                    }
                }
            } else {
                Map<String, String> result = new HashMap<String, String>();
                result.put("success", "false");
                result.put("message", message);
                result.put("error", new TranslatableMessage("serial.test.noTerminator").translate(Common.getTranslations()));
                results.add(result);
            }
        }
    } else {
        if (LOG.isDebugEnabled())
            LOG.debug("Matching will use String: " + msg);
        // Check all the points
        for (final DataPointVO vo : points) {
            final Map<String, String> result = new HashMap<String, String>();
            MatchCallback callback = new MatchCallback() {

                @Override
                public void onMatch(String pointIdentifier, PointValueTime pvt) {
                    result.put("name", vo.getName());
                    result.put("value", pvt.toString());
                    result.put("identifier", pointIdentifier);
                    result.put("success", "true");
                }

                @Override
                public void pointPatternMismatch(String message, String messageRegex) {
                    result.put("success", "false");
                    result.put("name", vo.getName());
                    result.put("error", new TranslatableMessage("serial.test.noPointRegexMatch").translate(Common.getTranslations()));
                }

                @Override
                public void messagePatternMismatch(String message, String messageRegex) {
                    result.put("success", "false");
                    result.put("name", vo.getName());
                    result.put("error", new TranslatableMessage("serial.test.noMessageMatch").translate(Common.getTranslations()));
                }

                @Override
                public void pointNotIdentified(String message, String messageRegex, int pointIdentifierIndex) {
                    result.put("success", "false");
                    result.put("name", vo.getName());
                    result.put("error", new TranslatableMessage("serial.test.noIdentifierFound").translate(Common.getTranslations()));
                }

                /* (non-Javadoc)
					 * @see com.infiniteautomation.mango.regex.MatchCallback#matchGeneralFailure(java.lang.Exception)
					 */
                @Override
                public void matchGeneralFailure(Exception e) {
                    result.put("success", "false");
                    result.put("name", vo.getName());
                    result.put("error", new TranslatableMessage("common.default", e.getMessage()).translate(Common.getTranslations()));
                }
            };
            try {
                SerialDataSourceRT.matchPointValue(msg, messageRegex, pointIdentifierIndex, (SerialPointLocatorVO) vo.getPointLocator(), isHex, LOG, callback);
            } catch (Exception e) {
                callback.matchGeneralFailure(e);
            }
            if (result.size() > 0) {
                result.put("message", msg);
                results.add(result);
            }
        }
    }
    return pr;
}
Also used : DataPointVO(com.serotonin.m2m2.vo.DataPointVO) DataPointDao(com.serotonin.m2m2.db.dao.DataPointDao) HashMap(java.util.HashMap) ProcessResult(com.serotonin.m2m2.i18n.ProcessResult) ArrayList(java.util.ArrayList) MatchCallback(com.infiniteautomation.mango.regex.MatchCallback) PointValueTime(com.serotonin.m2m2.rt.dataImage.PointValueTime) TranslatableMessage(com.serotonin.m2m2.i18n.TranslatableMessage) HashMap(java.util.HashMap) Map(java.util.Map) DwrPermission(com.serotonin.m2m2.web.dwr.util.DwrPermission)

Aggregations

MatchCallback (com.infiniteautomation.mango.regex.MatchCallback)4 TranslatableMessage (com.serotonin.m2m2.i18n.TranslatableMessage)4 PointValueTime (com.serotonin.m2m2.rt.dataImage.PointValueTime)4 IOException (java.io.IOException)3 AsciiFilePointLocatorVO (com.infiniteautomation.asciifile.vo.AsciiFilePointLocatorVO)2 ShouldNeverHappenException (com.serotonin.ShouldNeverHappenException)2 DataPointDao (com.serotonin.m2m2.db.dao.DataPointDao)2 ProcessResult (com.serotonin.m2m2.i18n.ProcessResult)2 DataPointRT (com.serotonin.m2m2.rt.dataImage.DataPointRT)2 DataPointVO (com.serotonin.m2m2.vo.DataPointVO)2 DwrPermission (com.serotonin.m2m2.web.dwr.util.DwrPermission)2 ArrayList (java.util.ArrayList)2 HashMap (java.util.HashMap)2 Map (java.util.Map)2 SerialPortException (com.infiniteautomation.mango.io.serial.SerialPortException)1 SerialPointLocatorVO (com.infiniteautomation.serial.vo.SerialPointLocatorVO)1 TimeoutTask (com.serotonin.m2m2.util.timeout.TimeoutTask)1 BufferedReader (java.io.BufferedReader)1 FileNotFoundException (java.io.FileNotFoundException)1 FileReader (java.io.FileReader)1