]> gerrit.simantics Code Review - simantics/platform.git/blob - bundles/org.simantics.databoard/src/org/simantics/databoard/parser/PrintFormat.java
Fixed all line endings of the repository
[simantics/platform.git] / bundles / org.simantics.databoard / src / org / simantics / databoard / parser / PrintFormat.java
1 /*******************************************************************************
2  *  Copyright (c) 2010 Association for Decentralized Information Management in
3  *  Industry THTH ry.
4  *  All rights reserved. This program and the accompanying materials
5  *  are made available under the terms of the Eclipse Public License v1.0
6  *  which accompanies this distribution, and is available at
7  *  http://www.eclipse.org/legal/epl-v10.html
8  *
9  *  Contributors:
10  *      VTT Technical Research Centre of Finland - initial API and implementation
11  *******************************************************************************/
12 package org.simantics.databoard.parser;
13
14 /**
15  * This class describes the representation format of string encoding.
16  *
17  * @author Toni Kalajainen <toni.kalajainen@vtt.fi>
18  */
19 public class PrintFormat {
20
21         public static final PrintFormat SINGLE_LINE;
22         public static final PrintFormat MULTI_LINE;     
23         
24         /** Indent sequence (Optional) */
25         public String indent = null;
26         /** New Line sequence (Optional) */
27         public String newLine = null;
28         
29         public char openArray = '[';
30         public char closeArray = ']';
31         public String arraySeparator = ",";
32         
33         public char openUnion = '(';
34         public char closeUnion = ')';
35
36         public char openTuple = '(';
37         public char closeTuple = ')';
38         
39         public char openRecord = '{';
40         public char closeRecord = '}';
41         
42         public char openString = '\"'; 
43         public char closeString = '\"';
44         
45         public String openLongString = "\"\"\""; 
46         public String closeLongString = "\"\"\"";
47         
48         public String True = "true";
49         public String False = "false";
50         public String Null = "null";
51         
52         static {
53                 PrintFormat f = new PrintFormat();
54                 {
55                         f.indent = null;
56                         f.newLine = null;
57                         
58                 }
59                 SINGLE_LINE = f;
60                 
61                 f = new PrintFormat();
62                 {
63                         f.indent = "\t";
64                         f.newLine = "\n";                       
65                 }
66                 MULTI_LINE = f;
67         }
68         
69 }
70