debugCheckHasTabBarState method

bool debugCheckHasTabBarState()

Asserts that this controller is currently attached to a TabBar's State.

To invoke this function, wrap it in an assert: assert(debugCheckHasTabBarState());

Does nothing if asserts are disabled. Always returns true.

Implementation

bool debugCheckHasTabBarState() {
  assert(_tabBarState != null, 'This TabBarScrollController is not attached to any TabBar.');

  return true;
}