Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
ServerResource クラスからアプリケーションの Router インスタンスにアクセスするにはどうすればよいですか? それは可能ですか?
前もって感謝します。
質問したときに、どうしてこれに対する答えが見つからなかったのかわかりません...しかし、それはかなり簡単です。「doInit」メソッドでは、次のようなことができます。
Router myRouter = (Router)this.getApplication.getRoot();
とてもシンプル!