public StreamNested<R> setOptionValue(long optionValue) { node.setOptionValue(new AstLiteralLongValue(optionValue)); return this; }
@Override protected boolean equalTo(AstRegion that) { return (that instanceof AstLiteralLongValue) && equalTo((AstLiteralLongValue) that); }
@Override public AstLiteralLongValue visitLiteralLong(LiteralLongContext ctx) { String literal = ctx.literal.getText().replaceAll("_", ""); AstLiteralLongValue value = new AstLiteralLongValue(Long.decode(literal)); value.setRegionInfo(asSequentialRegion(childInfos, ctx)); return value; }
@Override public MessageEncoder visit(AstLiteralLongValue value, Void parameter) { return new WriteLongEncoder(value.getValue()); }
@Override public AstValue<T> visitLiteralLong(LiteralLongContext ctx) { AstLiteralLongValueVisitor visitor = new AstLiteralLongValueVisitor(factory, environment); AstLiteralLongValue value = visitor.visit(ctx); if (value != null) { childInfos().add(value.getRegionInfo()); } return (AstValue<T>) value; }
@Override public Masker visit(AstLiteralLongValue literal, State state) { long value = literal.getValue(); if (value != 0L) { byte[] array = ByteBuffer.allocate(Long.BYTES) .putLong(value) .array(); return Maskers.newMasker(array); } // no need to unmask for all-zeros masking key return Masker.IDENTITY_MASKER; }
public StreamNested<R> setOptionValue(long optionValue) { node.setOptionValue(new AstLiteralLongValue(optionValue)); return this; }
public AstWriteOptionNodeBuilder setOptionValue(long optionValue) { node.setOptionValue(new AstLiteralLongValue(optionValue)); return this; }
public AstPropertyNodeBuilder setPropertyValue(long propertyValue) { node.setPropertyValue(new AstLiteralLongValue(propertyValue)); return this; }
public AstReadOptionNodeBuilder setOptionValue(long optionValue) { node.setOptionValue(new AstLiteralLongValue(optionValue)); return this; }
public AstWriteNodeBuilder addLong(Long value) { node.addValue(new AstLiteralLongValue(value)); return this; }
public StreamNested<R> addLong(Long value) { node.addValue(new AstLiteralLongValue(value)); return this; }
public ScriptNested<R> setPropertyValue(long propertyValue) { node.setPropertyValue(new AstLiteralLongValue(propertyValue)); return this; }
@Override public AstValue<T> visitLiteralInteger(LiteralIntegerContext ctx) { AstLiteralIntegerValueVisitor visitor = new AstLiteralIntegerValueVisitor(factory, environment); AstLiteralIntegerValue literal = visitor.visit(ctx); AstValue<?> value = literal; if (expectedType == long.class || expectedType == Long.class) { value = new AstLiteralLongValue(literal.getValue().longValue()); } if (value != null) { childInfos().add(value.getRegionInfo()); } return (AstValue<T>) value; }