1
0
mirror of https://github.com/octoleo/plantuml.git synced 2024-06-09 11:42:43 +00:00
plantuml/src/net/sourceforge/plantuml/preproc/Sub.java

61 lines
1.7 KiB
Java
Raw Normal View History

2017-02-01 18:55:51 +00:00
/* ========================================================================
* PlantUML : a free UML diagram generator
* ========================================================================
*
* (C) Copyright 2009-2017, Arnaud Roques
*
* Project Info: http://plantuml.com
*
2017-03-15 19:13:31 +00:00
* If you like this project or if you find it useful, you can support us at:
*
* http://plantuml.com/patreon (only 1$ per month!)
* http://plantuml.com/paypal
*
2017-02-01 18:55:51 +00:00
* This file is part of PlantUML.
*
* PlantUML is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* PlantUML distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
* or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
* License for more details.
*
* You should have received a copy of the GNU General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
* USA.
*
*
* Original Author: Arnaud Roques
*
*
*/
2017-11-20 16:10:36 +00:00
package net.sourceforge.plantuml.preproc;
2017-02-01 18:55:51 +00:00
2017-11-20 16:10:36 +00:00
import java.util.ArrayList;
import java.util.List;
2017-02-01 18:55:51 +00:00
2017-11-20 16:10:36 +00:00
import net.sourceforge.plantuml.CharSequence2;
import net.sourceforge.plantuml.LineLocation;
2017-02-01 18:55:51 +00:00
2017-11-20 16:10:36 +00:00
public class Sub {
2017-02-01 18:55:51 +00:00
2017-11-20 16:10:36 +00:00
private final String name;
private final List<CharSequence2> lines = new ArrayList<CharSequence2>();
2017-02-01 18:55:51 +00:00
2017-11-20 16:10:36 +00:00
public Sub(String name) {
this.name = name;
2017-02-01 18:55:51 +00:00
}
2017-11-20 16:10:36 +00:00
public void add(CharSequence2 s) {
this.lines.add(s);
}
2017-02-01 18:55:51 +00:00
2017-11-20 16:10:36 +00:00
public ReadLine getReadLine(LineLocation lineLocation) {
return new ReadLineList(lines, lineLocation);
2017-02-01 18:55:51 +00:00
}
2017-11-20 16:10:36 +00:00
}