00001
00002
00003
00004
00005
00006
00007
00008
00044 #ifdef _MSC_VER
00045 #pragma once
00046 #endif
00047
00048 #ifndef OGDF_OGML_H
00049 #define OGDF_OGML_H
00050
00051 #include <ogdf/basic/String.h>
00052
00053 namespace ogdf
00054 {
00055
00056
00059 const int TAG_NUM = 47, ATT_NUM = 48, ATT_VAL_NUM = 131;
00060
00061
00062 const int MAX_TAG_COUNT = 4000;
00063
00067 enum OgmlTagId
00068 {
00069 t_none = -1,
00070 t_bool,
00071 t_composed,
00072 t_constraint,
00073 t_constraints,
00074 t_content,
00075 t_data,
00076 t_default,
00077 t_edge,
00078 t_edgeRef,
00079 t_edgeStyle,
00080 t_edgeStyleTemplate,
00081 t_edgeStyleTemplateRef,
00082 t_endpoint,
00083 t_fill,
00084 t_font,
00085 t_graph,
00086 t_graphStyle,
00087 t_int,
00088 t_label,
00089 t_labelRef,
00090 t_labelStyle,
00091 t_labelStyleTemplate,
00092 t_labelStyleTemplateRef,
00093 t_layout,
00094 t_line,
00095 t_location,
00096 t_node,
00097 t_nodeRef,
00098 t_nodeStyle,
00099 t_nodeStyleTemplate,
00100 t_nodeStyleTemplateRef,
00101 t_num,
00102 t_ogml,
00103 t_point,
00104 t_port,
00105 t_segment,
00106 t_shape,
00107 t_source,
00108 t_sourceStyle,
00109 t_string,
00110 t_structure,
00111 t_styles,
00112 t_styleTemplates,
00113 t_target,
00114 t_targetStyle,
00115 t_text,
00116 t_image
00117 };
00118
00121 const String ogmlTagNames[] = {
00122
00123 "bool",
00124 "composed",
00125 "constraint",
00126 "constraints",
00127 "content",
00128 "data",
00129 "default",
00130 "edge",
00131 "edgeRef",
00132 "edgeStyle",
00133 "edgeStyleTemplate",
00134 "template",
00135 "endpoint",
00136 "fill",
00137 "font",
00138 "graph",
00139 "graphStyle",
00140 "int",
00141 "label",
00142 "labelRef",
00143 "labelStyle",
00144 "labelStyleTemplate",
00145 "template",
00146 "layout",
00147 "line",
00148 "location",
00149 "node",
00150 "nodeRef",
00151 "nodeStyle",
00152 "nodeStyleTemplate",
00153 "template",
00154 "num",
00155 "ogml",
00156 "point",
00157 "port",
00158 "segment",
00159 "shape",
00160 "source",
00161 "sourceStyle",
00162 "string",
00163 "structure",
00164 "styles",
00165 "styleTemplates",
00166 "target",
00167 "targetStyle",
00168 "text",
00169 "image"
00170 };
00171
00175 enum OgmlAttributeId
00176 {
00177 a_none = -1,
00178 a_alignment,
00179 a_angle,
00180 a_color,
00181 a_decoration,
00182 a_defaultEdgeTemplate,
00183 a_defaultLabelTemplate,
00184 a_defaultNodeTemplate,
00185 a_family,
00186 a_height,
00187 a_id,
00188 a_nodeIdRef,
00189 a_edgeIdRef,
00190 a_labelIdRef,
00191 a_sourceIdRef,
00192 a_targetIdRef,
00193 a_nodeStyleTemplateIdRef,
00194 a_edgeStyleTemplateIdRef,
00195 a_labelStyleTemplateIdRef,
00196 a_endpointIdRef,
00197 a_name,
00198 a_nLineType,
00199 a_nShapeType,
00200 a_pattern,
00201 a_patternColor,
00202 a_rotation,
00203 a_size,
00204 a_stretch,
00205 a_style,
00206 a_transform,
00207 a_type,
00208 a_uri,
00209 a_intValue,
00210 a_boolValue,
00211 a_numValue,
00212 a_variant,
00213 a_weight,
00214 a_width,
00215 a_x,
00216 a_y,
00217 a_z,
00218 a_imageUri,
00219 a_imageStyle,
00220 a_imageAlignment,
00221 a_imageDrawLine,
00222 a_imageWidth,
00223 a_imageHeight,
00224 a_constraintType,
00225 a_disabled
00226 };
00227
00230 const String ogmlAttributeNames[] = {
00231 "alignment",
00232 "angle",
00233 "color",
00234 "decoration",
00235 "defaultEdgeTemplate",
00236 "defaultLabelTemplate",
00237 "defaultNodeTemplate",
00238 "family",
00239 "height",
00240 "id",
00241 "idRef",
00242 "idRef",
00243 "idRef",
00244 "idRef",
00245 "idRef",
00246 "idRef",
00247 "idRef",
00248 "idRef",
00249 "idRef",
00250 "name",
00251 "type",
00252 "type",
00253 "pattern",
00254 "patternColor",
00255 "rotation",
00256 "size",
00257 "stretch",
00258 "style",
00259 "transform",
00260 "type",
00261 "uri",
00262 "value",
00263 "value",
00264 "value",
00265 "variant",
00266 "weight",
00267 "width",
00268 "x",
00269 "y",
00270 "z",
00271 "uri",
00272 "style",
00273 "alignment",
00274 "drawLine",
00275 "width",
00276 "height",
00277 "type",
00278 "disabled"
00279 };
00280
00284 enum OgmlAttributeValueId
00285 {
00286 av_any = 0,
00287 av_blink,
00288 av_bold,
00289 av_bolder,
00290 av_bool,
00291 av_box,
00292 av_capitalize,
00293 av_center,
00294 av_checked,
00295 av_circle,
00296 av_condensed,
00297 av_cursive,
00298 av_dashed,
00299 av_esNoPen,
00300 av_esSolid,
00301 av_esDash,
00302 av_esDot,
00303 av_esDashdot,
00304 av_esDashdotdot,
00305 av_diamond,
00306 av_dotted,
00307 av_double,
00308 av_doubleSlash,
00309 av_ellipse,
00310 av_expanded,
00311 av_extraCondensed,
00312 av_extraExpanded,
00313 av_fantasy,
00314 av_filledBox,
00315 av_filledCircle,
00316 av_filledDiamond,
00317 av_filledHalfBox,
00318 av_filledHalfCircle,
00319 av_filledHalfDiamond,
00320 av_filledHalfRhomb,
00321 av_filledRhomb,
00322 av_smurf,
00323 av_arrow,
00324 av_groove,
00325 av_halfBox,
00326 av_halfCircle,
00327 av_halfDiamond,
00328 av_halfRhomb,
00329 av_hexagon,
00330 av_hex,
00331 av_id,
00332 av_nodeIdRef,
00333 av_edgeIdRef,
00334 av_labelIdRef,
00335 av_sourceIdRef,
00336 av_targetIdRef,
00337 av_nodeStyleTemplateIdRef,
00338 av_edgeStyleTemplateIdRef,
00339 av_labelStyleTemplateIdRef,
00340 av_pointIdRef,
00341 av_image,
00342 av_inset,
00343 av_int,
00344 av_italic,
00345 av_justify,
00346 av_left,
00347 av_lighter,
00348 av_line,
00349 av_lineThrough,
00350 av_lowercase,
00351 av_lParallelogram,
00352 av_monospace,
00353 av_narrower,
00354 av_none,
00355 av_normal,
00356 av_num,
00357 av_oblique,
00358 av_oct,
00359 av_octagon,
00360 av_outset,
00361 av_overline,
00362 av_pentagon,
00363 av_rect,
00364 av_rectSimple,
00365 av_rhomb,
00366 av_ridge,
00367 av_right,
00368 av_rParallelogram,
00369 av_sansSerif,
00370 av_semiCondensed,
00371 av_semiExpanded,
00372 av_serif,
00373 av_slash,
00374 av_smallCaps,
00375 av_solid,
00376 av_bpNone,
00377 av_bpSolid,
00378 av_bpDense1,
00379 av_bpDense2,
00380 av_bpDense3,
00381 av_bpDense4,
00382 av_bpDense5,
00383 av_bpDense6,
00384 av_bpDense7,
00385 av_bpHorizontal,
00386 av_bpVertical,
00387 av_bpCross,
00388 av_bpBackwardDiagonal,
00389 av_bpForwardDiagonal,
00390 av_bpDiagonalCross,
00391 av_string,
00392 av_striped,
00393 av_trapeze,
00394 av_triangle,
00395 av_triple,
00396 av_ultraCondensed,
00397 av_ultraExpanded,
00398 av_umlClass,
00399 av_underline,
00400 av_uppercase,
00401 av_upTrapeze,
00402 av_uri,
00403 av_wider,
00404 av_freeScale,
00405 av_fixScale,
00406 av_topLeft,
00407 av_topCenter,
00408 av_topRight,
00409 av_centerLeft,
00410
00411 av_centerRight,
00412 av_bottomLeft,
00413 av_bottomCenter,
00414 av_bottomRight,
00415
00416 av_constraintAlignment,
00417 av_constraintAnchor,
00418 av_constraintSequence
00419 };
00420
00423 const String ogmlAttributeValueNames[] = {
00424 "any",
00425 "blink",
00426 "bold",
00427 "bolder",
00428 "bool",
00429 "box",
00430 "capitalize",
00431 "center",
00432 "checked",
00433 "circle",
00434 "condensed",
00435 "cursive",
00436 "dashed",
00437 "esNoPen",
00438 "esSolid",
00439 "esDash",
00440 "esDot",
00441 "esDashdot",
00442 "esDashdotdot",
00443 "diamond",
00444 "dotted",
00445 "double",
00446 "doubleSlash",
00447 "ellipse",
00448 "expanded",
00449 "extraCondensed",
00450 "extraExpanded",
00451 "fantasy",
00452 "filledBox",
00453 "filledCircle",
00454 "filledDiamond",
00455 "filledHalfBox",
00456 "filledHalfCircle",
00457 "filledHalfDiamond",
00458 "filledHalfRhomb",
00459 "filledRhomb",
00460 "smurf",
00461 "arrow",
00462 "groove",
00463 "halfBox",
00464 "halfCircle",
00465 "halfDiamond",
00466 "halfRhomb",
00467 "hexagon",
00468 "hex",
00469 "id",
00470 "nodeId",
00471 "edgeId",
00472 "labelId",
00473 "sourceId",
00474 "targetId",
00475 "nodeStyleTemplateId",
00476 "edgeStyleTemplateId",
00477 "labelStyleTemplateId",
00478 "pointId",
00479 "image",
00480 "inset",
00481 "int",
00482 "italic",
00483 "justify",
00484 "left",
00485 "lighter",
00486 "line",
00487 "lineThrough",
00488 "lowercase",
00489 "lParallelogram",
00490 "monospace",
00491 "narrower",
00492 "none",
00493 "normal",
00494 "num",
00495 "oblique",
00496 "oct",
00497 "octagon",
00498 "outset",
00499 "overline",
00500 "pentagon",
00501 "rect",
00502 "rectSimple",
00503 "rhomb",
00504 "ridge",
00505 "right",
00506 "rParallelogram",
00507 "sansSerif",
00508 "semiCondensed",
00509 "semiExpanded",
00510 "serif",
00511 "slash",
00512 "smallCaps",
00513 "solid",
00514 "bpNone",
00515 "bpSolid",
00516 "bpDense1",
00517 "bpDense2",
00518 "bpDense3",
00519 "bpDense4",
00520 "bpDense5",
00521 "bpDense6",
00522 "bpDense7",
00523 "bpHorizontal",
00524 "bpVertical",
00525 "bpCross",
00526 "bpBackwardDiagonal",
00527 "bpForwardDiagonal",
00528 "bpDiagonalCross",
00529 "string",
00530 "striped",
00531 "trapeze",
00532 "triangle",
00533 "triple",
00534 "ultraCondensed",
00535 "ultraExpanded",
00536 "umlClass",
00537 "underline",
00538 "uppercase",
00539 "upTrapeze",
00540 "uri",
00541 "wider",
00542 "freeScale",
00543 "fixScale",
00544 "topLeft",
00545 "topCenter",
00546 "topRight",
00547 "centerLeft",
00548
00549 "centerRight",
00550 "bottomLeft",
00551 "bottomCenter",
00552 "bottomRight",
00553 "Alignment",
00554 "Anchor",
00555 "Sequence"
00556 };
00557
00561 enum ValidityState
00562 {
00563 vs_tagEmptIncl = -10,
00564 vs_idNotUnique = -9,
00565 vs_idRefErr = -8,
00566 vs_unexpTag = -7,
00567 vs_unexpAtt = -6,
00568 vs_expTagNotFound = -5,
00569 vs_expAttNotFound = -4,
00570 vs_attValueErr = -3,
00571 vs_cardErr = -2,
00572 vs_invalid = -1,
00573 vs_valid = 1
00574 };
00575
00579 enum GraphType
00580 {
00581 graph,
00582 clusterGraph,
00583 compoundGraph,
00584 corruptCompoundGraph
00585 };
00586
00587 const String graphTypeS[] = {
00588 "graph",
00589 "clusterGraph",
00590 "compoundGraph",
00591 "corruptCompoundGraph"
00592 };
00593
00594 };
00595
00596 #endif //OGDF_OGML_H