package Ġcom . win dea . plugin . idea . stell aris . localization . psi Ċ Ċ import Ġcom . intellij . lang .* Ċ import Ġcom . intellij . lang . Parser Definition . Space Requirements .* Ċ import Ġcom . intellij . openapi . project .* Ċ import Ġcom . intellij . psi .* Ċ import Ġcom . intellij . psi . TokenType .* Ċ import Ġcom . intellij . psi . tree .* Ċ import Ġcom . win dea . plugin . idea . stell aris . localization .* Ċ import Ġcom . win dea . plugin . idea . stell aris . localization . psi . St ell aris Localization Types .* Ċ Ċ class ĠSt ell aris Localization Parser Definition Ġ: ĠParser Definition Ġ{ Ċ ĉ comp anion Ġobject Ġ{ Ċĉ ĉ val ĠWH ITE _ SP ACES Ġ= ĠToken Set . create ( WHITE _ SPACE ) Ċĉ ĉ val ĠCOMMENT S Ġ= ĠToken Set . create ( COMMENT , ĠROOT _ COMMENT , END _ OF _ LINE _ COMMENT ) Ċĉ ĉ val ĠSTR INGS Ġ= ĠToken Set . create ( STRING _ TOKEN ) Ċĉ ĉ val ĠFILE Ġ= ĠSt ell aris Localization Stub Element Types . FILE Ċ ĉ } ĊĊ ĉ override Ġfun Ġcreate Lexer ( project : ĠProject ?) Ġ= ĠSt ell aris Localization Lexer Adapter () ĊĊ ĉ override Ġfun Ġget Whitespace Tokens () Ġ= ĠWH ITE _ SP ACES ĊĊ ĉ override Ġfun Ġget Comment Tokens () Ġ= ĠCOMMENT S ĊĊ ĉ override Ġfun ĠgetString Literal Elements () Ġ= ĠSTR INGS ĊĊ ĉ override Ġfun Ġcreate Parser ( project : ĠProject ?) Ġ= ĠSt ell aris Localization Parser () ĊĉĊ ĉ override Ġfun ĠgetFile NodeType () Ġ= ĠFILE ĊĊ ĉ override Ġfun Ġcreate File ( view Provider : ĠFile View Provider ) Ġ= ĠSt ell aris Localization File ( view Provider ) ĊĊ ĉ override Ġfun Ġspace Ex istence Type Between Tokens ( left : ĠAST Node ?, Ġright : ĠAST Node ?): ĠParser Definition . Space Requirements Ġ{ Ċĉ ĉ return Ġwhen Ġ{ Ċĉĉ ĉ // æķ°åŃĹ åĴĮ å±ŀæĢ§ åĢ¼ ä¹ĭéĹ´ å¿ħé¡» æľī ç©º æł¼ Ċĉĉ ĉ left ?. elementType Ġ== ĠNUMBER Ġ&& Ġright ?. elementType Ġ== ĠPROPERTY _ VALUE Ġ-> ĠMUST Ċĉĉ ĉ // è¯Ńè¨Ģ åĮºåŁŁ ä¹ĭåīį å¿ħé¡» æį¢ è¡Į Ċĉĉ ĉ right ?. elementType Ġ== ĠLOCAL E Ġ-> ĠMUST _ LINE _ BREAK Ċĉĉ ĉ // å±ŀæĢ§ ä¹ĭåīį å¿ħé¡» æį¢ è¡Į Ċĉĉ ĉ right ?. elementType Ġ== ĠPROPERTY Ġ-> ĠMUST _ LINE _ BREAK Ċĉĉ ĉ else Ġ-> ĠMAY Ċĉ ĉ } Ċ ĉ } ĊĊ ĉ override Ġfun ĠcreateElement ( node : ĠAST Node ) Ġ= ĠSt ell aris Localization Types . Factory . createElement ( node ) Ċ } ĊĊĊ