- java.lang.Object
-
- org.tentackle.model.parse.Line
-
- org.tentackle.model.parse.MultiLine
-
- org.tentackle.model.parse.OptionLine
-
public class OptionLine extends MultiLine
The option line.Option lines start with an attribute or relation name followed by a colon and may span more than one line. Options are separated by commas.
- Author:
- harald
-
-
Constructor Summary
Constructors Constructor Description OptionLine(Document document, int offset, LineType lineType)Creates an attribute option line.
May span multiple lines.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetName()Gets the attribute or relation name.java.util.List<java.lang.String>getOptions()Gets the options.voidparse()Parses a line.-
Methods inherited from class org.tentackle.model.parse.Line
assertParsed, createModelException, createModelException, getDocument, getLength, getLineNumber, getLineType, getOffset, getSourceInfo, getText, setLength, toString
-
-
-
-
Method Detail
-
parse
public void parse() throws ModelExceptionDescription copied from class:LineParses a line.- Overrides:
parsein classMultiLine- Throws:
ModelException- if parsing failed
-
getName
public java.lang.String getName() throws ModelExceptionGets the attribute or relation name.- Returns:
- the attribute name, never null or empty
- Throws:
ModelException- if not parsed
-
getOptions
public java.util.List<java.lang.String> getOptions() throws ModelExceptionGets the options.- Returns:
- the options, never null
- Throws:
ModelException- if not parsed
-
-