@armyc2.c5isr.renderer/mil-sym-ts-web 2.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (170) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +57 -0
  3. package/buildNode.bat +2 -0
  4. package/buildWeb.bat +2 -0
  5. package/dist/C5Ren.d.ts +6970 -0
  6. package/dist/C5Ren.js +2 -0
  7. package/dist/C5Ren.js.map +1 -0
  8. package/dist/LICENSE +201 -0
  9. package/dist/README.md +57 -0
  10. package/dist/armyc2.c5isr.renderer-mil-sym-ts-web-2.2.0.tgz +0 -0
  11. package/dist/manifest.json +4 -0
  12. package/dist/package.json +16 -0
  13. package/index.ts +169 -0
  14. package/package.bak +50 -0
  15. package/package.json +40 -0
  16. package/package.node.json +43 -0
  17. package/package.pack.json +19 -0
  18. package/package.packWeb.json +16 -0
  19. package/package.web.json +40 -0
  20. package/src/main/ts/android/graphics/Bitmap.ts +7 -0
  21. package/src/main/ts/android/graphics/Paint.ts +26 -0
  22. package/src/main/ts/android/graphics/Path.ts +78 -0
  23. package/src/main/ts/android/graphics/PointF.ts +14 -0
  24. package/src/main/ts/android/graphics/Rect.ts +18 -0
  25. package/src/main/ts/android/graphics/RectF.ts +50 -0
  26. package/src/main/ts/android/graphics/Region.ts +36 -0
  27. package/src/main/ts/android/graphics/Typeface.ts +11 -0
  28. package/src/main/ts/armyc2/c5isr/JavaLineArray/BasicShapes.ts +99 -0
  29. package/src/main/ts/armyc2/c5isr/JavaLineArray/CChannelPoints2.ts +34 -0
  30. package/src/main/ts/armyc2/c5isr/JavaLineArray/CELineArray.ts +193 -0
  31. package/src/main/ts/armyc2/c5isr/JavaLineArray/Channels.ts +2971 -0
  32. package/src/main/ts/armyc2/c5isr/JavaLineArray/DISMSupport.ts +4008 -0
  33. package/src/main/ts/armyc2/c5isr/JavaLineArray/POINT2.ts +93 -0
  34. package/src/main/ts/armyc2/c5isr/JavaLineArray/Shape2.ts +89 -0
  35. package/src/main/ts/armyc2/c5isr/JavaLineArray/TacticalLines.ts +515 -0
  36. package/src/main/ts/armyc2/c5isr/JavaLineArray/arraysupport.ts +5403 -0
  37. package/src/main/ts/armyc2/c5isr/JavaLineArray/countsupport.ts +1084 -0
  38. package/src/main/ts/armyc2/c5isr/JavaLineArray/flot.ts +2173 -0
  39. package/src/main/ts/armyc2/c5isr/JavaLineArray/lineutility.ts +4934 -0
  40. package/src/main/ts/armyc2/c5isr/JavaLineArray/ref.ts +7 -0
  41. package/src/main/ts/armyc2/c5isr/JavaTacticalRenderer/Modifier2.ts +5601 -0
  42. package/src/main/ts/armyc2/c5isr/JavaTacticalRenderer/P1.ts +14 -0
  43. package/src/main/ts/armyc2/c5isr/JavaTacticalRenderer/TGLight.ts +648 -0
  44. package/src/main/ts/armyc2/c5isr/JavaTacticalRenderer/clsChannelUtility.ts +647 -0
  45. package/src/main/ts/armyc2/c5isr/JavaTacticalRenderer/clsMETOC.ts +2994 -0
  46. package/src/main/ts/armyc2/c5isr/JavaTacticalRenderer/clsUtility.ts +2663 -0
  47. package/src/main/ts/armyc2/c5isr/JavaTacticalRenderer/mdlGeodesic.ts +669 -0
  48. package/src/main/ts/armyc2/c5isr/RenderMultipoints/clsClipPolygon2.ts +971 -0
  49. package/src/main/ts/armyc2/c5isr/RenderMultipoints/clsClipQuad.ts +871 -0
  50. package/src/main/ts/armyc2/c5isr/RenderMultipoints/clsRenderer.ts +3507 -0
  51. package/src/main/ts/armyc2/c5isr/RenderMultipoints/clsRenderer2.ts +500 -0
  52. package/src/main/ts/armyc2/c5isr/RenderMultipoints/clsUtility.ts +1089 -0
  53. package/src/main/ts/armyc2/c5isr/RenderMultipoints/clsUtilityCPOF.ts +2656 -0
  54. package/src/main/ts/armyc2/c5isr/RenderMultipoints/clsUtilityGE.ts +1419 -0
  55. package/src/main/ts/armyc2/c5isr/data/genc.json +1407 -0
  56. package/src/main/ts/armyc2/c5isr/data/msd.json +17311 -0
  57. package/src/main/ts/armyc2/c5isr/data/mse.json +18500 -0
  58. package/src/main/ts/armyc2/c5isr/data/svgd.json +31214 -0
  59. package/src/main/ts/armyc2/c5isr/data/svge.json +30558 -0
  60. package/src/main/ts/armyc2/c5isr/graphics2d/AffineTransform.ts +10 -0
  61. package/src/main/ts/armyc2/c5isr/graphics2d/Area.ts +437 -0
  62. package/src/main/ts/armyc2/c5isr/graphics2d/BasicStroke.ts +429 -0
  63. package/src/main/ts/armyc2/c5isr/graphics2d/BasicTypes.ts +7 -0
  64. package/src/main/ts/armyc2/c5isr/graphics2d/BufferedImage.ts +35 -0
  65. package/src/main/ts/armyc2/c5isr/graphics2d/Font.ts +111 -0
  66. package/src/main/ts/armyc2/c5isr/graphics2d/FontMetrics.ts +29 -0
  67. package/src/main/ts/armyc2/c5isr/graphics2d/FontRenderContext.ts +18 -0
  68. package/src/main/ts/armyc2/c5isr/graphics2d/GeneralPath.ts +211 -0
  69. package/src/main/ts/armyc2/c5isr/graphics2d/Graphics2D.ts +80 -0
  70. package/src/main/ts/armyc2/c5isr/graphics2d/IPathIterator.ts +33 -0
  71. package/src/main/ts/armyc2/c5isr/graphics2d/ImageIO.ts +16 -0
  72. package/src/main/ts/armyc2/c5isr/graphics2d/Line2D.ts +726 -0
  73. package/src/main/ts/armyc2/c5isr/graphics2d/PathIterator.ts +141 -0
  74. package/src/main/ts/armyc2/c5isr/graphics2d/Point.ts +112 -0
  75. package/src/main/ts/armyc2/c5isr/graphics2d/Point2D.ts +261 -0
  76. package/src/main/ts/armyc2/c5isr/graphics2d/Polygon.ts +391 -0
  77. package/src/main/ts/armyc2/c5isr/graphics2d/Rectangle.ts +567 -0
  78. package/src/main/ts/armyc2/c5isr/graphics2d/Rectangle2D.ts +445 -0
  79. package/src/main/ts/armyc2/c5isr/graphics2d/Shape.ts +31 -0
  80. package/src/main/ts/armyc2/c5isr/graphics2d/Stroke.ts +18 -0
  81. package/src/main/ts/armyc2/c5isr/graphics2d/TextLayout.ts +45 -0
  82. package/src/main/ts/armyc2/c5isr/graphics2d/TexturePaint.ts +25 -0
  83. package/src/main/ts/armyc2/c5isr/renderer/IIconRenderer.ts +15 -0
  84. package/src/main/ts/armyc2/c5isr/renderer/IconRenderer.ts +22 -0
  85. package/src/main/ts/armyc2/c5isr/renderer/MilStdIconRenderer.ts +269 -0
  86. package/src/main/ts/armyc2/c5isr/renderer/ModifierRenderer.ts +9882 -0
  87. package/src/main/ts/armyc2/c5isr/renderer/PatternFillRenderer.ts +146 -0
  88. package/src/main/ts/armyc2/c5isr/renderer/SinglePointSVGRenderer.ts +1265 -0
  89. package/src/main/ts/armyc2/c5isr/renderer/shapes/arc.ts +64 -0
  90. package/src/main/ts/armyc2/c5isr/renderer/shapes/bcurve.ts +95 -0
  91. package/src/main/ts/armyc2/c5isr/renderer/shapes/ellipse.ts +93 -0
  92. package/src/main/ts/armyc2/c5isr/renderer/shapes/line.ts +114 -0
  93. package/src/main/ts/armyc2/c5isr/renderer/shapes/path.ts +555 -0
  94. package/src/main/ts/armyc2/c5isr/renderer/shapes/pathiterator.ts +62 -0
  95. package/src/main/ts/armyc2/c5isr/renderer/shapes/point.ts +120 -0
  96. package/src/main/ts/armyc2/c5isr/renderer/shapes/rectangle.ts +431 -0
  97. package/src/main/ts/armyc2/c5isr/renderer/shapes/roundedrectangle.ts +99 -0
  98. package/src/main/ts/armyc2/c5isr/renderer/shapes/types.ts +25 -0
  99. package/src/main/ts/armyc2/c5isr/renderer/shapes/utilities.ts +203 -0
  100. package/src/main/ts/armyc2/c5isr/renderer/utilities/AffiliationColors.ts +104 -0
  101. package/src/main/ts/armyc2/c5isr/renderer/utilities/Color.ts +481 -0
  102. package/src/main/ts/armyc2/c5isr/renderer/utilities/DistanceUnit.ts +40 -0
  103. package/src/main/ts/armyc2/c5isr/renderer/utilities/DrawRules.ts +1323 -0
  104. package/src/main/ts/armyc2/c5isr/renderer/utilities/EntityCode.ts +51 -0
  105. package/src/main/ts/armyc2/c5isr/renderer/utilities/ErrorLogger.ts +736 -0
  106. package/src/main/ts/armyc2/c5isr/renderer/utilities/GENCLookup.ts +106 -0
  107. package/src/main/ts/armyc2/c5isr/renderer/utilities/GeoPixelConversion3D.ts +84 -0
  108. package/src/main/ts/armyc2/c5isr/renderer/utilities/IMultiPointRenderer.ts +87 -0
  109. package/src/main/ts/armyc2/c5isr/renderer/utilities/IPointConversion.ts +34 -0
  110. package/src/main/ts/armyc2/c5isr/renderer/utilities/ImageInfo.ts +324 -0
  111. package/src/main/ts/armyc2/c5isr/renderer/utilities/LRUCache.ts +127 -0
  112. package/src/main/ts/armyc2/c5isr/renderer/utilities/LRUEntry.ts +18 -0
  113. package/src/main/ts/armyc2/c5isr/renderer/utilities/LogLevel.ts +111 -0
  114. package/src/main/ts/armyc2/c5isr/renderer/utilities/MODrawRules.ts +219 -0
  115. package/src/main/ts/armyc2/c5isr/renderer/utilities/MSInfo.ts +1008 -0
  116. package/src/main/ts/armyc2/c5isr/renderer/utilities/MSLookup.ts +882 -0
  117. package/src/main/ts/armyc2/c5isr/renderer/utilities/MilStdAttributes.ts +380 -0
  118. package/src/main/ts/armyc2/c5isr/renderer/utilities/MilStdSymbol.ts +797 -0
  119. package/src/main/ts/armyc2/c5isr/renderer/utilities/Modifiers.ts +1699 -0
  120. package/src/main/ts/armyc2/c5isr/renderer/utilities/PointConversion.ts +178 -0
  121. package/src/main/ts/armyc2/c5isr/renderer/utilities/PointConversionDummy.ts +45 -0
  122. package/src/main/ts/armyc2/c5isr/renderer/utilities/PointConverter3D.ts +126 -0
  123. package/src/main/ts/armyc2/c5isr/renderer/utilities/RectUtilities.ts +118 -0
  124. package/src/main/ts/armyc2/c5isr/renderer/utilities/RendererException.ts +11 -0
  125. package/src/main/ts/armyc2/c5isr/renderer/utilities/RendererSettings.ts +1201 -0
  126. package/src/main/ts/armyc2/c5isr/renderer/utilities/RendererUtilities.ts +591 -0
  127. package/src/main/ts/armyc2/c5isr/renderer/utilities/SVGInfo.ts +29 -0
  128. package/src/main/ts/armyc2/c5isr/renderer/utilities/SVGLookup.ts +753 -0
  129. package/src/main/ts/armyc2/c5isr/renderer/utilities/SVGSymbolInfo.ts +137 -0
  130. package/src/main/ts/armyc2/c5isr/renderer/utilities/SVGTextInfo.ts +438 -0
  131. package/src/main/ts/armyc2/c5isr/renderer/utilities/SettingsChangedEvent.ts +19 -0
  132. package/src/main/ts/armyc2/c5isr/renderer/utilities/SettingsChangedEventListener.ts +10 -0
  133. package/src/main/ts/armyc2/c5isr/renderer/utilities/SettingsEventListener.ts +5 -0
  134. package/src/main/ts/armyc2/c5isr/renderer/utilities/Shape2SVG.ts +404 -0
  135. package/src/main/ts/armyc2/c5isr/renderer/utilities/ShapeInfo.ts +525 -0
  136. package/src/main/ts/armyc2/c5isr/renderer/utilities/ShapeUtilities.ts +55 -0
  137. package/src/main/ts/armyc2/c5isr/renderer/utilities/SymbolDimensionInfo.ts +36 -0
  138. package/src/main/ts/armyc2/c5isr/renderer/utilities/SymbolID.ts +1055 -0
  139. package/src/main/ts/armyc2/c5isr/renderer/utilities/SymbolUtilities.ts +2085 -0
  140. package/src/main/ts/armyc2/c5isr/renderer/utilities/TextInfo.ts +157 -0
  141. package/src/main/ts/armyc2/c5isr/web/render/GeoPixelConversion.ts +86 -0
  142. package/src/main/ts/armyc2/c5isr/web/render/MultiPointHandler.ts +3798 -0
  143. package/src/main/ts/armyc2/c5isr/web/render/MultiPointHandlerSVG.ts +412 -0
  144. package/src/main/ts/armyc2/c5isr/web/render/PointConverter.ts +124 -0
  145. package/src/main/ts/armyc2/c5isr/web/render/SymbolModifiers.ts +26 -0
  146. package/src/main/ts/armyc2/c5isr/web/render/WebRenderer.ts +677 -0
  147. package/src/main/ts/armyc2/c5isr/web/render/utilities/JavaRendererUtilities.ts +484 -0
  148. package/src/main/ts/armyc2/c5isr/web/render/utilities/LineInfo.ts +62 -0
  149. package/src/main/ts/armyc2/c5isr/web/render/utilities/SymbolInfo.ts +46 -0
  150. package/src/main/ts/armyc2/c5isr/web/render/utilities/TextInfo.ts +51 -0
  151. package/src/main/ts/org/gavaghan/geodesy/Angle.ts +31 -0
  152. package/src/main/ts/org/gavaghan/geodesy/Ellipsoid.ts +71 -0
  153. package/src/main/ts/org/gavaghan/geodesy/GeodeticCalculator.ts +200 -0
  154. package/src/main/ts/org/gavaghan/geodesy/GeodeticCurve.ts +55 -0
  155. package/src/main/ts/org/gavaghan/geodesy/GeodeticMeasurement.ts +68 -0
  156. package/src/main/ts/org/gavaghan/geodesy/GlobalCoordinates.ts +103 -0
  157. package/src/main/ts/org/gavaghan/geodesy/GlobalPosition.ts +90 -0
  158. package/test/ExportSPImages.js +692 -0
  159. package/test/MPWW.html +556 -0
  160. package/test/MPWorker.js +318 -0
  161. package/test/SPWorker.js +233 -0
  162. package/test/SVGWW.html +363 -0
  163. package/test/singlePointTester3.html +751 -0
  164. package/tsconfig.json +54 -0
  165. package/typedoc.json +30 -0
  166. package/updateVersion.js +21 -0
  167. package/webpack.config.js +34 -0
  168. package/webpackn.config.js +28 -0
  169. package/webpackr.config.js +47 -0
  170. package/webpackw.config.js +23 -0
@@ -0,0 +1,127 @@
1
+ import { type int } from "../../graphics2d/BasicTypes";
2
+ import { ImageInfo } from "../../renderer/utilities/ImageInfo"
3
+ import { LRUEntry } from "../../renderer/utilities/LRUEntry"
4
+
5
+
6
+
7
+ /**
8
+ * Modified LRUCache implementation from: https://techblogstation.com/java/lru-cache-implementation-in-java/
9
+ * and
10
+ * https://www.baeldung.com/java-lru-cache
11
+ */
12
+
13
+
14
+ //The class for LRU Cache storage and its operations
15
+ export class LRUCache {
16
+
17
+ // Variable to store the least recently used element
18
+ private lruElement: LRUEntry;
19
+
20
+ // Variable to store the most recently used element
21
+ private mruElement: LRUEntry;
22
+
23
+ private container: Map<string, LRUEntry>;
24
+ private capacity: int = 0;
25
+ private currentSize: int = 0;
26
+
27
+ //private readonly lock: java.util.concurrent.locks.ReentrantReadWriteLock = new java.util.concurrent.locks.ReentrantReadWriteLock();
28
+
29
+ // Constructor for setting the values in instance variables
30
+ public constructor(capacity: int) {
31
+ this.capacity = capacity;
32
+ this.currentSize = 0;
33
+ this.lruElement = new LRUEntry(null, null, null, null);
34
+ this.mruElement = this.lruElement;
35
+ this.container = new Map<string, LRUEntry>();
36
+ }
37
+
38
+ // The get method to perform the retrieve operations on data
39
+ public get(key: string): ImageInfo | null {
40
+ //this.lock.readLock().lock();
41
+ try {
42
+ let tempLRUEntry: LRUEntry = this.container.get(key);
43
+ if (tempLRUEntry == null) {
44
+ return null;
45
+ }
46
+ // In case the MRU leave the list as it is :
47
+ else {
48
+ if (tempLRUEntry.key === this.mruElement.key) {
49
+ return this.mruElement.value;
50
+ }
51
+ }
52
+
53
+
54
+ // Getting the Next and Previous Nodes
55
+ let nextLRUEntry: LRUEntry = tempLRUEntry.next;
56
+ let prevLRUEntry: LRUEntry = tempLRUEntry.prev;
57
+
58
+ // If LRU is updated at the left-most
59
+ if (tempLRUEntry.key === this.lruElement.key) {
60
+ nextLRUEntry.prev = null;
61
+ this.lruElement = nextLRUEntry;
62
+ }
63
+
64
+ // In case we are in the middle, we are required to update the items before and
65
+ // after our item
66
+ else {
67
+ if (tempLRUEntry.key !== this.mruElement.key) {
68
+ prevLRUEntry.next = nextLRUEntry;
69
+ nextLRUEntry.prev = prevLRUEntry;
70
+ }
71
+ }
72
+
73
+
74
+ // And here we are finally moving our item to MRU
75
+ tempLRUEntry.prev = this.mruElement;
76
+ this.mruElement.next = tempLRUEntry;
77
+ this.mruElement = tempLRUEntry;
78
+ this.mruElement.next = null;
79
+
80
+ return tempLRUEntry.value;
81
+ }
82
+ finally {
83
+ // this.lock.readLock().unlock();
84
+ }
85
+
86
+ }
87
+
88
+ // The put method to perform the insert operations on cache
89
+
90
+ public put(key: string, value: ImageInfo): void {
91
+ //this.lock.writeLock().lock();
92
+ try {
93
+ if (this.container.has(key)) {
94
+ return;
95
+ }
96
+
97
+ // Inserting the new Node at the right-most end position of the linked-list
98
+ let myLRUEntry: LRUEntry = new LRUEntry(this.mruElement, null, key, value);
99
+ this.mruElement.next = myLRUEntry;
100
+ this.container.set(key, myLRUEntry);
101
+ this.mruElement = myLRUEntry;
102
+
103
+ // Deleting the entry of position left-most of LRU cache and also updating the
104
+ // LRU pointer
105
+ if (this.currentSize === this.capacity) {
106
+ this.container.delete(this.lruElement.key);
107
+ this.lruElement = this.lruElement.next;
108
+ this.lruElement.prev = null;
109
+ }
110
+
111
+ // Updating the size of container for the firstly added entry and updating the
112
+ // LRU pointer
113
+ else {
114
+ if (this.currentSize < this.capacity) {
115
+ if (this.currentSize === 0) {
116
+ this.lruElement = myLRUEntry;
117
+ }
118
+ this.currentSize++;
119
+ }
120
+ }
121
+
122
+ }
123
+ finally {
124
+ //this.lock.writeLock().unlock();
125
+ }
126
+ }
127
+ }
@@ -0,0 +1,18 @@
1
+ import { ImageInfo } from "../../renderer/utilities/ImageInfo"
2
+
3
+ //The Node class for doubly linked list
4
+ export class LRUEntry {
5
+
6
+ public key: string;
7
+ public value: ImageInfo;
8
+ public next: LRUEntry;
9
+ public prev: LRUEntry;
10
+
11
+ public constructor(prev: LRUEntry, next: LRUEntry, key: string, value: ImageInfo) {
12
+ this.prev = prev;
13
+ this.next = next;
14
+ this.key = key;
15
+ this.value = value;
16
+ }
17
+
18
+ }
@@ -0,0 +1,111 @@
1
+ /**
2
+ * Port of java.util.logging.Level class
3
+ */
4
+ export class LogLevel {
5
+ /**
6
+ * OFF is a special level that can be used to turn off logging.
7
+ * This level is initialized to <CODE>Integer.MAX_VALUE</CODE>.
8
+ */
9
+ public static OFF = new LogLevel("OFF", Number.MAX_VALUE);
10
+
11
+ /**
12
+ * SEVERE is a message level indicating a serious failure.
13
+ * <p>
14
+ * In general SEVERE messages should describe events that are
15
+ * of considerable importance and which will prevent normal
16
+ * program execution. They should be reasonably intelligible
17
+ * to end users and to system administrators.
18
+ * This level is initialized to <CODE>1000</CODE>.
19
+ */
20
+ public static SEVERE = new LogLevel("SEVERE", 1000);
21
+
22
+ /**
23
+ * WARNING is a message level indicating a potential problem.
24
+ * <p>
25
+ * In general WARNING messages should describe events that will
26
+ * be of interest to end users or system managers, or which
27
+ * indicate potential problems.
28
+ * This level is initialized to <CODE>900</CODE>.
29
+ */
30
+ public static WARNING = new LogLevel("WARNING", 900);
31
+
32
+ /**
33
+ * INFO is a message level for informational messages.
34
+ * <p>
35
+ * Typically INFO messages will be written to the console
36
+ * or its equivalent. So the INFO level should only be
37
+ * used for reasonably significant messages that will
38
+ * make sense to end users and system administrators.
39
+ * This level is initialized to <CODE>800</CODE>.
40
+ */
41
+ public static INFO = new LogLevel("INFO", 800);
42
+
43
+ /**
44
+ * CONFIG is a message level for static configuration messages.
45
+ * <p>
46
+ * CONFIG messages are intended to provide a variety of static
47
+ * configuration information, to assist in debugging problems
48
+ * that may be associated with particular configurations.
49
+ * For example, CONFIG message might include the CPU type,
50
+ * the graphics depth, the GUI look-and-feel, etc.
51
+ * This level is initialized to <CODE>700</CODE>.
52
+ */
53
+ public static CONFIG = new LogLevel("CONFIG", 700);
54
+
55
+ /**
56
+ * FINE is a message level providing tracing information.
57
+ * <p>
58
+ * All of FINE, FINER, and FINEST are intended for relatively
59
+ * detailed tracing. The exact meaning of the three levels will
60
+ * vary between subsystems, but in general, FINEST should be used
61
+ * for the most voluminous detailed output, FINER for somewhat
62
+ * less detailed output, and FINE for the lowest volume (and
63
+ * most important) messages.
64
+ * <p>
65
+ * In general the FINE level should be used for information
66
+ * that will be broadly interesting to developers who do not have
67
+ * a specialized interest in the specific subsystem.
68
+ * <p>
69
+ * FINE messages might include things like minor (recoverable)
70
+ * failures. Issues indicating potential performance problems
71
+ * are also worth logging as FINE.
72
+ * This level is initialized to <CODE>500</CODE>.
73
+ */
74
+ public static FINE = new LogLevel("FINE", 500);
75
+
76
+ /**
77
+ * FINER indicates a fairly detailed tracing message.
78
+ * By default logging calls for entering, returning, or throwing
79
+ * an exception are traced at this level.
80
+ * This level is initialized to <CODE>400</CODE>.
81
+ */
82
+ public static FINER = new LogLevel("FINER", 400);
83
+
84
+ /**
85
+ * FINEST indicates a highly detailed tracing message.
86
+ * This level is initialized to <CODE>300</CODE>.
87
+ */
88
+ public static FINEST = new LogLevel("FINEST", 300);
89
+
90
+ /**
91
+ * ALL indicates that all messages should be logged.
92
+ * This level is initialized to <CODE>Integer.MIN_VALUE</CODE>.
93
+ */
94
+ public static ALL = new LogLevel("ALL", Number.MIN_VALUE);
95
+
96
+ private name: string
97
+ private value: number = 0;
98
+
99
+ constructor(name: string, value: number) {
100
+ this.name = name;
101
+ this.value = value;
102
+ }
103
+
104
+ intValue(): number {
105
+ return this.value;
106
+ }
107
+
108
+ getName(): string {
109
+ return this.name;
110
+ }
111
+ }
@@ -0,0 +1,219 @@
1
+ /**
2
+ * Draw Rules for METEOROLOGICAL AND OCEANOGRAPHIC SYMBOLOGY
3
+ *
4
+ */
5
+ export class MODrawRules {
6
+
7
+ /**
8
+ * Usually an entry in the MilStd that is just a category containing other symbols
9
+ * and not something that gets drawn itself.
10
+ */
11
+ public static readonly DONOTDRAW: number = 0;
12
+
13
+ /**
14
+ * Anchor Points: This graphic requires at least three anchor points to
15
+ * define the boundary of the area. Add as many points as necessary to
16
+ * accurately reflect the area's size and shape.
17
+ * Size/Shape: Scalable.
18
+ * Orientation: Not applicable.
19
+ */
20
+ public static readonly AREA1: number = 101;
21
+
22
+ /**
23
+ * Anchor Points: This graphic requires at least three anchor points to
24
+ * define the boundary of the area. Add as many points as necessary to
25
+ * accurately reflect the area's size and shape.
26
+ * Size/Shape: Determined by the anchor points.
27
+ * Orientation: Not applicable.
28
+ */
29
+ public static readonly AREA2: number = 102;
30
+
31
+
32
+ /**
33
+ * Anchor Points: This graphic requires one anchor point. The center point
34
+ * defines the center of the graphic.
35
+ * Size/Shape: Scalable.
36
+ * Orientation: The graphic is typically centered over the desired location.
37
+ */
38
+ public static readonly POINT1: number = 201;
39
+
40
+ /**
41
+ * Anchor Points: This graphic requires one anchor point. The center point
42
+ * defines the geometric center of the graphic.
43
+ * Size/Shape: Scalable.
44
+ * Orientation: The graphic is centered over the anchor location.
45
+ */
46
+ public static readonly POINT2: number = 202;
47
+
48
+ /**
49
+ * Anchor Points: This graphic requires one anchor point. The center point
50
+ * defines the center of the graphic.
51
+ * Size/Shape: Scalable.
52
+ * Orientation: The graphic is oriented upright on the display and operator-centered over the desired location.
53
+ */
54
+ public static readonly POINT3: number = 203;
55
+
56
+
57
+ /**
58
+ * Anchor Points: This graphic requires one anchor point. The center point
59
+ * defines the center of the graphic.
60
+ * Size/Shape: Scalable.
61
+ * Orientation: The graphic is centered over the location of the reported wind.
62
+ */
63
+ public static readonly POINT4: number = 204;
64
+
65
+
66
+ /**
67
+ * Anchor Points: This graphic requires a minimum of two anchor points.
68
+ * The first point defines the location of the plot circle.
69
+ * Additional points define the wind shaft and the speed of the wind.
70
+ * Wind speed is depicted on the shaft using a combination of the shaft
71
+ * alone (1-2 knots), half barbs (5 knots), barbs (10 knots)
72
+ * and pennants (50 knots). Wind speeds 5 knots or greater are rounded
73
+ * to the nearest 5 knots. Missing wind speed is depicted by an "X" at
74
+ * the end of the wind shaft. Winds with missing direction are not displayed.
75
+ *
76
+ * Size/Shape: Not applicable.
77
+ *
78
+ * Orientation: The shaft of the graphic is oriented with reference to
79
+ * true north in the direction from which the wind is blowing to the
80
+ * nearest 10 degrees. The barbs and pennants lie back from the shaft at
81
+ * an angle of 120 degrees and are oriented to the left of the shaft in
82
+ * the Northern Hemisphere and to the right in the Southern Hemisphere.
83
+ * The graphic is operator-centered over the desired location.
84
+ */
85
+ public static readonly POINT5: number = 205;
86
+
87
+ /**
88
+ * Anchor Points: This graphic requires one anchor point. The center point
89
+ * defines the center of the graphic.
90
+ * Size/Shape: Scalable.
91
+ * Orientation: The graphic is centered over the location of the reported cloud cover.
92
+ */
93
+ public static readonly POINT6: number = 206;
94
+
95
+ /**
96
+ * Anchor Points: This graphic requires one anchor point. The center point
97
+ * defines the center of the graphic.
98
+ * Size/Shape: Scalable.
99
+ * Orientation: The graphic is centered over the location of the reported conditions.
100
+ */
101
+ public static readonly POINT7: number = 207;
102
+
103
+ /**
104
+ * Anchor Points: This graphic requires one anchor point. The center point
105
+ * defines the center of the graphic.
106
+ * Size/Shape: Scalable.
107
+ * Orientation: The graphic is centered over the position of the tropical system.
108
+ */
109
+ public static readonly POINT8: number = 208;
110
+
111
+ /**
112
+ * Anchor Points: This graphic requires at least two anchor points,
113
+ * points 1 and 2, to define the line. Additional points can be defined
114
+ * to extend the line.
115
+ * Size/Shape: Scalable/Curve. The curvature of the line is operator defined.
116
+ * Orientation: The first and last anchor points determine the length of
117
+ * the line.
118
+ */
119
+ public static readonly LINE1: number = 301;
120
+
121
+ /**
122
+ * Anchor Points: This graphic requires at least two anchor points,
123
+ * points 1 and 2, to define the line. Additional points can be defined to
124
+ * extend the line.
125
+ *
126
+ * Size/Shape: Scalable/Curve. The points are typically connected with a
127
+ * straight line consisting of a short line section and an alternating
128
+ * V shape. The curvature and amplitude of the waves of the line is
129
+ * operator defined.
130
+ *
131
+ * Orientation: The first and last anchor points determine the length of
132
+ * the line. The line should be drawn so the "V" shapes are facing in
133
+ * the direction of movement. The "V" shapes and short line segment will
134
+ * alternate along the line.
135
+ */
136
+ public static readonly LINE2: number = 302;
137
+
138
+ /**
139
+ * Anchor Points: This graphic requires at least two anchor points,
140
+ * points 1 and 2, to define the line. Additional points can be defined to
141
+ * extend the line.
142
+ *
143
+ * Size/Shape: Scalable/Curve. The points are typically connected with a
144
+ * straight line consisting of a short line section and alternating two
145
+ * dots. The curvature and amplitude of the waves of the line is
146
+ * operator defined.
147
+ *
148
+ * Orientation: The first and last anchor points determine the length of the line. The two dots and the short line segment will alternate along the line.
149
+ */
150
+ public static readonly LINE3: number = 303;
151
+
152
+ /**
153
+ * Anchor Points: This graphic requires at least two anchor points,
154
+ * points 1 and 2, to define the line. Additional points can be defined to
155
+ * extend the line.
156
+ *
157
+ * Size/Shape: Scalable/Curve. The points are typically connected with a
158
+ * curved/wavy line consisting of a short line and one dot. The curvature
159
+ * and amplitude of the waves of the line is operator defined.
160
+ *
161
+ * Orientation: The first and last anchor points determine the length of
162
+ * the line. The dot and the short line segment will alternate along
163
+ * the line.
164
+ */
165
+ public static readonly LINE4: number = 304;
166
+
167
+ /**
168
+ * Anchor Points: This graphic requires at least three anchor points to
169
+ * define the boundary of the area. Add as many points as necessary to
170
+ * accurately reflect the area's size and shape.
171
+ *
172
+ * Size/Shape: Determined by the anchor points.
173
+ *
174
+ * Orientation: The first and last anchor points determine the length of
175
+ * the line. The dual line segments will be parallel to slightly wider at
176
+ * the western end.
177
+ */
178
+ public static readonly LINE5: number = 305;
179
+
180
+ /**
181
+ * Anchor Points: This graphic requires at least two anchor points,
182
+ * points 1 and 2, to define the line. Additional points can be defined to
183
+ * extend the line.
184
+ * Size/Shape: Scalable/Curve. The points are typically connected with a
185
+ * solid straight line with alternating slanted lines connected as depicted
186
+ * in the example to indicate convergence.
187
+ * Orientation: The first and last anchor points determine the length of
188
+ * the line. The alternating slanted lines will be evenly spaced along
189
+ * the line. Orientation is determined by the anchor points.
190
+ */
191
+ public static readonly LINE6: number = 306;
192
+
193
+ /**
194
+ * Anchor Points: This graphic requires at least two anchor points,
195
+ * points 1 and 2, to define the line. Additional points can be defined to
196
+ * extend the line.
197
+ *
198
+ * Size/Shape: Scalable/Curve. The points are typically connected with a
199
+ * dashed straight or curved line. The curvature of the line is operator
200
+ * defined.
201
+ *
202
+ * Orientation: The first and last anchor points determine the length of
203
+ * the line. The red and green line segments will alternate along the line.
204
+ * Orientation is determined by the anchor points.
205
+ */
206
+ public static readonly LINE7: number = 307;
207
+
208
+ /**
209
+ * Anchor Points: This graphic requires at least two anchor points,
210
+ * points 1 and 2, to define the line. Additional points can be defined to
211
+ * extend the line.
212
+ * Size/Shape: Scalable.
213
+ * Orientation: The graphic is oriented upright on the display as shown in
214
+ * the example and operator-centered over the desired location.
215
+ */
216
+ public static readonly LINE8: number = 308;
217
+
218
+
219
+ }