import 'package:flutter/material.dart'; import 'package:go_router/go_router.dart'; import 'package:oc_front/pages/abstract_page.dart'; class DatacenterFactory implements AbstractFactory { @override GlobalKey getKey() { return key; } @override void clear() { } static GlobalKey key = GlobalKey(); @override bool searchFill() { return false; } @override Widget factory(GoRouterState state, List args) { return ComputePageWidget(); } @override void search(BuildContext context, bool special) { } } class ComputePageWidget extends StatefulWidget { ComputePageWidget () : super(key: DatacenterFactory.key); @override ComputePageWidgetState createState() => ComputePageWidgetState(); static Widget factory() { return ComputePageWidget(); } } class ComputePageWidgetState extends State { @override Widget build(BuildContext context) { return Column( children: []); } }