writeInto method

  1. @override
void writeInto(
  1. GenerationContext context
)
override

Writes this component into the context by writing to its GenerationContext.buffer or by introducing bound variables. When writing into the buffer, no whitespace around the this component should be introduced. When a component consists of multiple composed component, it's responsible for introducing whitespace between its child components.

Implementation

@override
void writeInto(GenerationContext context) {
  if (offset != null) {
    context.buffer.write('LIMIT $amount OFFSET $offset');
  } else {
    context.buffer.write('LIMIT $amount');
  }
}