3 " (ISO-10165-4; Guidelines for the Definition of Managed Object)
4 " Maintainer: Gyuman Kim <violino@dooly.modacom.co.kr>
5 " URL: http://dooly.modacom.co.kr/gdmo.vim
6 " Last change: 2001 Sep 02
8 " For version 5.x: Clear all syntax items
9 " For version 6.x: Quit when a syntax file was already loaded
12 elseif exists("b:current_syntax")
17 syn match gdmoCategory "MANAGED\s\+OBJECT\s\+CLASS"
18 syn keyword gdmoCategory NOTIFICATION ATTRIBUTE BEHAVIOUR PACKAGE ACTION
19 syn match gdmoCategory "NAME\s\+BINDING"
20 syn match gdmoRelationship "DERIVED\s\+FROM"
21 syn match gdmoRelationship "SUPERIOR\s\+OBJECT\s\+CLASS"
22 syn match gdmoRelationship "SUBORDINATE\s\+OBJECT\s\+CLASS"
23 syn match gdmoExtension "AND\s\+SUBCLASSES"
24 syn match gdmoDefinition "DEFINED\s\+AS"
25 syn match gdmoDefinition "REGISTERED\s\+AS"
26 syn match gdmoExtension "ORDER\s\+BY"
27 syn match gdmoReference "WITH\s\+ATTRIBUTE"
28 syn match gdmoReference "WITH\s\+INFORMATION\s\+SYNTAX"
29 syn match gdmoReference "WITH\s\+REPLY\s\+SYNTAX"
30 syn match gdmoReference "WITH\s\+ATTRIBUTE\s\+SYNTAX"
31 syn match gdmoExtension "AND\s\+ATTRIBUTE\s\+IDS"
32 syn match gdmoExtension "MATCHES\s\+FOR"
33 syn match gdmoReference "CHARACTERIZED\s\+BY"
34 syn match gdmoReference "CONDITIONAL\s\+PACKAGES"
35 syn match gdmoExtension "PRESENT\s\+IF"
36 syn match gdmoExtension "DEFAULT\s\+VALUE"
37 syn match gdmoExtension "PERMITTED\s\+VALUES"
38 syn match gdmoExtension "REQUIRED\s\+VALUES"
39 syn match gdmoExtension "NAMED\s\+BY"
40 syn keyword gdmoReference ATTRIBUTES NOTIFICATIONS ACTIONS
41 syn keyword gdmoExtension DELETE CREATE
42 syn keyword gdmoExtension EQUALITY SUBSTRINGS ORDERING
43 syn match gdmoExtension "REPLACE-WITH-DEFAULT"
44 syn match gdmoExtension "GET"
45 syn match gdmoExtension "GET-REPLACE"
46 syn match gdmoExtension "ADD-REMOVE"
47 syn match gdmoExtension "WITH-REFERENCE-OBJECT"
48 syn match gdmoExtension "WITH-AUTOMATIC-INSTANCE-NAMING"
49 syn match gdmoExtension "ONLY-IF-NO-CONTAINED-OBJECTS"
52 " Strings and constants
53 syn match gdmoSpecial contained "\\\d\d\d\|\\."
54 syn region gdmoString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=gdmoSpecial
55 syn match gdmoCharacter "'[^\\]'"
56 syn match gdmoSpecialCharacter "'\\.'"
57 syn match gdmoNumber "0[xX][0-9a-fA-F]\+\>"
58 syn match gdmoLineComment "--.*"
59 syn match gdmoLineComment "--.*--"
61 syn match gdmoDefinition "^\s*[a-zA-Z][-a-zA-Z0-9_.\[\] \t{}]* *::="me=e-3
62 syn match gdmoBraces "[{}]"
64 syn sync ccomment gdmoComment
66 " Define the default highlighting.
67 " For version 5.7 and earlier: only when not done already
68 " For version 5.8 and later: only when an item doesn't have highlighting yet
69 if version >= 508 || !exists("did_gdmo_syntax_inits")
71 let did_gdmo_syntax_inits = 1
72 command -nargs=+ HiLink hi link <args>
74 command -nargs=+ HiLink hi def link <args>
77 HiLink gdmoCategory Structure
78 HiLink gdmoRelationship Macro
79 HiLink gdmoDefinition Statement
80 HiLink gdmoReference Type
81 HiLink gdmoExtension Operator
82 HiLink gdmoBraces Function
83 HiLink gdmoSpecial Special
84 HiLink gdmoString String
85 HiLink gdmoCharacter Character
86 HiLink gdmoSpecialCharacter gdmoSpecial
87 HiLink gdmoComment Comment
88 HiLink gdmoLineComment gdmoComment
94 let b:current_syntax = "gdmo"