Search in sources :

Example 51 with Stream

use of com.ramussoft.pb.Stream in project ramus by Vitaliy-Yakovchuk.

the class SectorRowsEditor method getStream.

public Stream getStream() {
    if (!sectorNameEditor.jTextField.getText().equals("")) {
        final Stream r = sectorNameEditor.findStreamByName(sectorNameEditor.jTextField.getText());
        if (r != null && !r.equals(stream)) {
            rows = r.getAdded();
            rowsModel.refresh();
            return r;
        }
    }
    if (stream == null) {
        if (!sectorNameEditor.jTextField.getText().equals("")) {
            final Stream r = sectorNameEditor.findStreamByName(sectorNameEditor.jTextField.getText());
            if (r != null) {
                stream = r;
                return stream;
            }
            stream = (Stream) dataPlugin.createRow(dataPlugin.getBaseStream(), true);
            stream.setRows(rows);
            // if(!stream.getTitle().equals(jTextField.getText()))
            stream.setName(sectorNameEditor.jTextField.getText());
        }
    }
    return stream;
}
Also used : Stream(com.ramussoft.pb.Stream)

Aggregations

Stream (com.ramussoft.pb.Stream)51 Row (com.ramussoft.pb.Row)30 Function (com.ramussoft.pb.Function)21 Sector (com.ramussoft.pb.Sector)18 ByteArrayOutputStream (java.io.ByteArrayOutputStream)15 NSector (com.ramussoft.pb.data.negine.NSector)14 Vector (java.util.Vector)13 InputStream (java.io.InputStream)11 PaintSector (com.ramussoft.pb.idef.elements.PaintSector)10 ByteArrayInputStream (java.io.ByteArrayInputStream)10 Crosspoint (com.ramussoft.pb.Crosspoint)9 NFunction (com.ramussoft.pb.data.negine.NFunction)9 OutputStream (java.io.OutputStream)7 NStream (com.ramussoft.pb.data.negine.NStream)6 ArrayList (java.util.ArrayList)6 FloatPoint (com.dsoft.pb.types.FloatPoint)4 SectorRefactor (com.ramussoft.pb.idef.elements.SectorRefactor)4 MovingFunction (com.ramussoft.pb.idef.visual.MovingFunction)4 IOException (java.io.IOException)4 FRectangle (com.dsoft.pb.types.FRectangle)3