private String decimal() throws FHIRException { StringBuffer res = new StringBuffer(Utilities.padLeft("", ' ', MAX_TERM_LIMIT)); int i = 0; fixed('#'); while ((peek() >= '0' && peek() <= '9') || peek() == '.') { res.setCharAt(i, next()); i++; } return res.substring(0, i); }
private Expression attributeValue() throws FHIRException { Expression res; ws(); if (gchar('(')) { res = expression(); fixed(')'); } else { res = expression(); } return res; }
private Refinement attribute() throws FHIRException { Refinement res = new Refinement(); res.setStart(cursor); res.name = attributeName(); fixed('='); res.value = attributeValue(); ws(); res.setStop(cursor); return res; }
private Concept attributeName() throws FHIRException { Concept res = new Concept(); res.setStart(cursor); ws(); res.code = conceptId(); ws(); if (gchar('|')) { ws(); res.description = term(); ws(); fixed('|'); ws(); } res.setStop(cursor); return res; }
private Concept concept() throws FHIRException { Concept res = new Concept(); res.setStart(cursor); ws(); if (peek() == '#') res.decimal = decimal(); else if (peek() == '"') res.literal = stringConstant(); else res.code = conceptId(); ws(); if (gchar('|')) { ws(); res.description = term().trim(); ws(); fixed('|'); ws(); } res.setStop(cursor); return res; }
private String decimal() throws FHIRException { StringBuffer res = new StringBuffer(Utilities.padLeft("", ' ', MAX_TERM_LIMIT)); int i = 0; fixed('#'); while ((peek() >= '0' && peek() <= '9') || peek() == '.') { res.setCharAt(i, next()); i++; } return res.substring(0, i); }
private Expression attributeValue() throws FHIRException { Expression res; ws(); if (gchar('(')) { res = expression(); fixed(')'); } else { res = expression(); } return res; }
private Refinement attribute() throws FHIRException { Refinement res = new Refinement(); res.setStart(cursor); res.name = attributeName(); fixed('='); res.value = attributeValue(); ws(); res.setStop(cursor); return res; }
private Concept attributeName() throws FHIRException { Concept res = new Concept(); res.setStart(cursor); ws(); res.code = conceptId(); ws(); if (gchar('|')) { ws(); res.description = term(); ws(); fixed('|'); ws(); } res.setStop(cursor); return res; }
private Concept concept() throws FHIRException { Concept res = new Concept(); res.setStart(cursor); ws(); if (peek() == '#') res.decimal = decimal(); else if (peek() == '"') res.literal = stringConstant(); else res.code = conceptId(); ws(); if (gchar('|')) { ws(); res.description = term().trim(); ws(); fixed('|'); ws(); } res.setStop(cursor); return res; }