@Override public QueryPath parse(final String path) { final QueryPath result = new QueryPath(); final String[] elements = path.split(PATH_SEPARATOR); for (String element : elements) { element = element.trim(); if (!element.isEmpty()) { Integer index = null; try { index = Integer.valueOf(element); } catch (final Exception e) { // do nothing } if (index == null) { result.add(new Data.StringKey(element)); } else { result.add(new Data.IntegerKey(index)); } } } return result; }
translationPath.add(new Data.StringKey(qPath.toString())); translationPath.add(new Data.StringKey("_runtimeData")); translationPath.add(new Data.IntegerKey((Integer)p.getKey())); translationPath.add(new Data.StringKey("id-translation")); String translation = model.get(translationPath.toString());
public Value getValue() { if (basicWidget instanceof KSTextBox) { StringValue value = new StringValue(((KSTextBox)basicWidget).getText()); return value; } else if (basicWidget instanceof KSSuggestBox) { //Do check here if(!config.isRepeating){ StringValue value = new StringValue(((KSSuggestBox) basicWidget).getValue()); return value; } else{ Data data = new Data(); data.set(new Data.IntegerKey(0),((KSSuggestBox) basicWidget).getValue()); DataValue value = new DataValue(data); return value; } } else if (basicWidget instanceof KSSelectItemWidgetAbstract) { return SelectItemWidgetBinding.INSTANCE.getWidgetValue((KSSelectItemWidgetAbstract)basicWidget); } return null; }
public void set(final Integer key, final Short value) { put(new IntegerKey(key), new ShortValue(value)); }
public void set(final Integer key, final Integer value) { put(new IntegerKey(key), new IntegerValue(value)); }
public void add(final String value) { put(new IntegerKey(map.size()), new StringValue(value)); }
public void add(final Short value) { put(new IntegerKey(map.size()), new ShortValue(value)); }
public void add(final Float value) { put(new IntegerKey(map.size()), new FloatValue(value)); }
public void add(final Double value) { put(new IntegerKey(map.size()), new DoubleValue(value)); }
public void add(final Boolean value) { put(new IntegerKey(map.size()), new BooleanValue(value)); }
public void set(final Integer key, final Timestamp value) { put(new IntegerKey(key), new TimestampValue(value)); }
public void set(final Integer key, final Time value) { put(new IntegerKey(key), new TimeValue(value)); }
public void set(final Integer key, final Double value) { put(new IntegerKey(key), new DoubleValue(value)); }
public void add(final Integer value) { put(new IntegerKey(map.size()), new IntegerValue(value)); }
public void add(final Date value) { put(new IntegerKey(map.size()), new DateValue(value)); }
public void set(final Integer key, final String value) { put(new IntegerKey(key), new StringValue(value)); }
public void set(final Integer key, final Float value) { put(new IntegerKey(key), new FloatValue(value)); }
public void set(final Integer key, final Boolean value) { put(new IntegerKey(key), new BooleanValue(value)); }
public void add(final Long value) { put(new IntegerKey(map.size()), new LongValue(value)); }
public void set(final Integer key, final Data value) { final Key k = new IntegerKey(key); put(k, new DataValue(value)); if (value != null) { value.parent = this; value.parentKey = k; } }