⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 teacherlayerfigure.java

📁 拥有图形界面的
💻 JAVA
字号:
/* * TeacherLayerFigure.java * * Created on 31 maggio 2001, 23.07 */package org.joone.edit;import java.util.*;import java.awt.Color;import CH.ifa.draw.standard.*;import org.joone.engine.*;import org.joone.engine.learning.*;import org.joone.io.*;public class TeacherLayerFigure extends OutputLayerFigure {        private static final long serialVersionUID = -7092869490372528874L;        /** Creates new TeacherLayerFigure */    public TeacherLayerFigure() {    }        protected Vector addHandles(Vector handles) {        handles.addElement(new SpecialConnectionHandle(this, RelativeLocator.north(),        new DesiredLayerConnection(), Color.red));        handles.addElement(new ConnectionHandle(this, RelativeLocator.east(),        new LayerConnection()));        //new ErrorLayerConnection()));        return handles;    }        public boolean addPreConn(LayerFigure figure, InputPatternListener synapse) {        boolean ret = super.addPreConn(figure, synapse);        if (figure instanceof InputLayerFigure) {            ComparingElement ts = (ComparingElement)getOutputLayer();            ts.setDesired((StreamInputSynapse)synapse);        }        return ret;    }        public void removePreConn(LayerFigure figure, InputPatternListener conn) {        super.removePreConn(figure);        if (figure instanceof InputLayerFigure) {            ComparingElement ts = (ComparingElement)getOutputLayer();            ts.setDesired(null);        }    }        public void addPostConn(LayerFigure figure, OutputPatternListener synapse) {        super.addPostConn(figure, synapse);        if (!fPostConn.contains(figure)) {        //if (figure instanceof OutputLayerFigure) {            ComparingElement ts = (ComparingElement)getOutputLayer();            ts.addResultSynapse(synapse);        }    }        public void removePostConn(LayerFigure figure, OutputPatternListener conn) {        removePostConn(figure);        //if (figure instanceof OutputLayerFigure) {            ComparingElement ts = (ComparingElement)getOutputLayer();            ts.removeResultSynapse(conn);        //}    }    }

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -