apply method

T apply(
  1. void block(
    1. T self
    )
)

Executes block with value as 'this' context and returns the original value Usage: StringBuilder().apply((self) => self..write('Hello')..write('World'))

Implementation

T apply(void Function(T self) block) {
  block(this);
  return this;
}