Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.
获取包含服务器启动时所构造的启动类的数组。
Object[] ServerContext.getStartClassInstances()
返回包含服务器启动时所构造的启动类的数组,或者如果没有启动类,则返回长度为零的数组。
有关详细信息,请参见用户定义的启动类。
以下示例演示如何使用 [getStartClassInstances] 方法:
Object objs[] = sc.getStartClassInstances(); int i; for (i=0; i < objs.length; i += 1) { if (objs[i] instanceof MyClass) { // Use class. } }