]> gerrit.simantics Code Review - simantics/sysdyn.git/blob
01b3a12550071dd3d69a5db782dab58fd3816112
[simantics/sysdyn.git] /
1 package org.simantics.sysdyn.modelImport.model;\r
2 \r
3 import org.simantics.sysdyn.modelImport.MdlUtils.CommentIcon;\r
4 \r
5 public class ModelElementFactory {\r
6         \r
7         public static void getConnection() {\r
8                 \r
9         }\r
10         \r
11         public static void getDependency() {\r
12                 \r
13         }\r
14         \r
15         public static void getFlow() {\r
16                 \r
17         }\r
18         \r
19         public static Element2 getElement(SketchVariable variable) {\r
20                 if (variable.getVariable().getExpression() instanceof IntegralExpression) {\r
21                         return getStock(variable);\r
22                 }\r
23                 else {\r
24                         return getAuxiliary(variable);\r
25                 }\r
26         }\r
27         \r
28         public static Element2 getElement(SketchValve valve) {\r
29                 return getValve(valve);\r
30         }\r
31         \r
32         public static Element2 getElement(SketchComment comment) {\r
33                 if (comment.getIcon().equals(CommentIcon.CLOUD)) {\r
34                         return getCloud(comment);\r
35                 }\r
36                 else {\r
37                         return getComment(comment);\r
38                 }\r
39         }\r
40         \r
41         public static Auxiliary2 getAuxiliary(SketchVariable variable) {\r
42                 return null;\r
43         }\r
44         \r
45         public static Stock2 getStock(SketchVariable variable) {\r
46                 assert variable.getVariable().getExpression() instanceof IntegralExpression;\r
47                 \r
48                 return null;\r
49         }\r
50         \r
51         public static Valve2 getValve(SketchValve valve) {\r
52                 return null;\r
53         }\r
54         \r
55         public static Cloud2 getCloud(SketchComment comment) {\r
56                 assert comment.getIcon().equals(CommentIcon.CLOUD);\r
57                 return null;\r
58         }\r
59         \r
60         public static Comment2 getComment(SketchComment comment) {\r
61                 return null;\r
62         }\r
63         \r
64         public static Shadow2 getShadow(SketchVariable variable) {\r
65                 return null;\r
66         }\r
67 \r
68 }\r